Merging DataTemplateDictionaries

I’ve run into another problem with having multiple palettes… is there a way I can merge NodeTemplateDictionary’s? I’ve set up separate dictionaries for each of the categories in the palette, but need them all merged together for the diagram’s template dictionary. For now I’ve just copied all of the DataTemplate’s in the dictionaries and pasted them into another dictionary for the diagram, but would like to find a cleaner way to accomplish this.

Thanks again
Ryan

I don’t know if you can do that in XAML.
Because Microsoft explicitly added a separate mechanism for merging ResourceDictionaries, I would guess the answer is no.

So if you want to do that in GoXam, you’ll need to do it in code.
Have the DataTemplates defined in separate resources and merge them normally in XAML.
Define an empty DataTemplateDictionary in XAML.
Upon initialization, insert all of those DataTemplates into your DataTemplateDictionary.

Because Silverlight 3 didn’t support defining and populating DataTemplateDictionaries in XAML, all of the samples do exactly what I’m talking about in code.