wpf - XAML - MergedDictionaries throwing XmlParseException "item has already been added". Why? -
i have following, easy reproduce problem: i'm creating xaml application uses resources file. way go create mergeddictionaries-tag merge local , global resources, this: <window> <window.resources> <resourcedictionary> <resourcedictionary.mergeddictionaries> <resourcedictionary source="path.to.xaml.file"/> <resourcedictionary> <style targettype="{x:type border}" x:key="typeblock"> </style> <style targettype="{x:type border}" x:key="setblock"> </style> </resourcedictionary> </resourcedictionary.mergeddictionaries> </resourcedictionary> </window.resources> .... </window> this little piece of code crash if run it: item has been added. key in dictionary: 'system.windows.controls.border' key being added: ...