In my solution, I have one application project, which defines all the resources - like brushes and styles. I want to access these resources in views of other projects, which are Prism modules and they get resolved at run time.
For example, I have the following defined in my Silverlight application's App.xaml:
<LinearGradientBrush x:Key="MyBrush" EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="#FFFFA700" Offset="0.482" />
<GradientStop Color="#FFFF7600" Offset="0.864" />
<GradientStop Color="#FFFFB400" Offset="0.169" />
</LinearGradientBrush>
Now, I want to use this brush in one of the Prism modules like this:
<Border Background="{StaticResource MyBrush}"/>
Note that the modules are resolved using XAML Module Catalog. The above line is marked as error in the designer, although it gets properly resolved at runtime.
What would be the best way to define resources in a silverlight modular application so that they can be accessed in all the modules without the designer errors?