I'm having problems of using two different kinds of resources definitions in the resources section of a XAML file:
This throws an error:
<Window.Resources> <XmlDataProvider x:Key="Maschinen"> <x:XData xmlns=""> <machines> <machine name="alte Maschine"/> <machine name="neue Maschine"/> </machines> </x:XData> </XmlDataProvider> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="ShinyRed.xaml"/> </ResourceDictionary.MergedDictionaries> </ResourceDictionary> </Window.Resources> and this also:
<Window.Resources> <XmlDataProvider x:Key="Maschinen"> <x:XData xmlns=""> <machines> <machine name="alte Maschine"/> <machine name="neue Maschine"/> </machines> </x:XData> </XmlDataProvider> <ResourceDictionary Source="ShinyRed.xaml"/> </Window.Resources> Does anyone know what I have to do to avoid error messages? Thank you!
<ResourceDictionary x:Key="ResDict01" Source="ShinyRed.xaml"/>But then I don't know how to access the ResourceDictionary the styles in the ResourceDictionary do not work any longer.