views:

17

answers:

1

Hello,

working on a pretty large library of controls the generic.xaml gets simpy out of control. I want to split it pretty much by control (although once for a namespace which contains only some simple ones for now).

For that, i am adding more Resource Dictionaries.

Then, in the generic.Xaml I add:

<ResourceDictionary.MergedDictionaries>
    <ResourceDictionary Source="Themes/Generic.Core.xaml" />
</ResourceDictionary.MergedDictionaries>

And... get a loading error.

What is the correct URL?

This is:

  • Within a dll file containing only controls (not an exe or something).
  • The generic.Xaml and the other one (for now: Generic.Core.xaml) live in the same assembly, same folder.

I read the MSDN part about the pack URL's but that sounds really complicated for something that looks SO easy.

;) Please help.

A: 

Found it:

<ResourceDictionary.MergedDictionaries>
    <ResourceDictionary Source="/Tradex.Presentation;component/Themes/Generic.Core.xaml" />
</ResourceDictionary.MergedDictionaries>

That works. Needs to prefix the assembly and start with the "component" item.

TomTom