4

the line ResourceDictionary Source="..." ist underlined and the VS designer throws an Exception. Everything was working in VS 2008

<ResourceDictionary>
    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="pack://application:,,,/MySolution.MyProject;component/Styles/MyStyles.xaml" />
    </ResourceDictionary.MergedDictionaries>
</ResourceDictionary>

Exception:

Exception:Value cannot be null. Parameter name: item (Same for the InnerException) at Microsoft.Expression.Platform.InstanceBuilders.ClrObjectInstanceBuilder.InstantiateChildren(IInstanceBuilderContext context, ViewNode viewNode, DocumentCompositeNode compositeNode, Boolean isNewInstance)

theSpyCry
  • 12,073
  • 28
  • 96
  • 152

1 Answers1

0

what is the "build Action" set for your MyStyles.xaml?

try setting this to "page" if it is not already set-up like this.

see this other answer for details: (it seems to me that this could be related in a way)

Style TargetType causes XamlParseException when not attached to debugger

David
  • 6,014
  • 4
  • 39
  • 55