views:

13

answers:

0

Hi,

I have the following type of setup for my WPF Application.

App.exe
UI.Styles.dll
UI.Controls.dll
Component1.Views.dll
Component2.Views.dll
(and various other parts)

I want to be able to use the design surfaces to pick my control styles - e.g. we have a border that has a "round corner + shading + border" graphical style which belongs in UI.Styles.

My App.exe is a winforms app that creates a WPF application in code. I've found that using DynamicResource, and creating a merged dictionary as part of the WPF instantiation works perfectly at runtime.

Expression then prompts for DesignTimeResource - and I've added my dictionaries from UI.Styles into the DesignTimeExtension.xaml. This means that when I have a dynamic resource extension applied, and reload my designer, Blend will pick up on my resources and display them.

However, I don't have access to my brushes or styles to pick and apply from Blend, so end up having to go into the Xaml, look at the other project and copy and paste resource names, which is a major hassle - and defeats some of the purpose of using Blend.

Has anyone any suggestion as to how I can make this work, or how I can alter my workflow to better support right click > apply resource >

Thanks, Chris