我收到以下错误:Microsoft.Windows.Controls是否缺少程序集引用?
Error 26 The type or namespace name 'Controls' does not exist in the namespace 'Microsoft.Windows' (are you missing an assembly reference?)
这两个组件出现在.g.cs文件:
using Microsoft.Windows.Controls;
using Microsoft.Windows.Controls.Primitives;
当我删除它们,错误再次出现。
您定位的是什么.net版本? Microsoft.Windows.Controls&Controls.Primitives自.NET 3.0以来。 –
这些不是标准的命名空间名称。通常需要最小的repro XAML片段来诊断此问题。你需要检查一个简单的“hello world”项目,只需一个Window编译就可以了。 –