I'm trying to build my project and I keep getting these error messages:
Error 1 The type 'System.Windows.Markup.IQueryAmbient' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Xaml, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. C:\Users\Geoff\Git\My Shopping List\My Shopping List\RunWindowItemList.xaml.cs 24 26 My Shopping List
Error 2 The type name 'IComponentConnector' could not be found in the namespace 'System.Windows.Markup'. This type has been forwarded to assembly 'System.Xaml, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' Consider adding a reference to that assembly. C:\Users\Geoff\Git\My Shopping List\My Shopping List\obj\Debug\RunWindowItemList.g.cs 40 91 My Shopping List
I tried looking up on MSDN how to remedy the situation, but I haven't found anything. If anyone can help me with a solution or an article that has the solution, I would appreciate it!
To open the XAML Designer, right-click a XAML file in Solution Explorer and choose View Designer. to switch which window appears on top: either the artboard or the XAML editor.
You can change this behavior by going to Tools -> Options -> Projects and Solutions -> General and deselecting the "Always show Error List if build finishes with errors".
I had the same problem and after adding System.Xaml.dll
to my References the problem resolved!
Check version of System.Xaml.dll used in your project and compare to .net version of this project. Seems you use old version System.Xaml.dll. You can find other dll in folder C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With