How to use a StaticResource Brush's Color?

Viewed 5282

I have a brush as a Resource:

<Application.Resources>
    <SolidColorBrush x:Key="AppBrush" Color="#FFFFFF"/>
</Application.Resources>

and I want to use it's Color:

<... BackgroundColor="{StaticResource AppBrush.Color}"/>

But it isn't possible and I get a xaml corruption error. How can I do that?

or in other away how to use Brush's Color in another Color resource:

<Application.Resources>
    <Color x:Key="AppColor">#FFFFFF { here how to use AppBrush.Color?}</Color>
    <SolidColorBrush x:Key="AppBrush" Color="#FFFFFF"/>
</Application.Resources>
2 Answers
Related