我不確定爲什麼,但最近Visual Studio似乎無法在根窗口上找到在XAML中使用的模式。如何修復Visual Studio 2010中的模式/命名空間錯誤? (WPF/XAML)
這是錯誤消息我得到:
消息1未能找到元素「http://schemas.microsoft.com/winfx/2006/xaml/presentation:Window架構信息」。
錯誤導致IntelliSense無法正常工作。但是,該項目仍按預期進行編譯和運行。在我打開的每個項目中,問題都是一樣的。從一個新的項目開始給我以下的XAML:
<Window x:Class="WpfApplication2.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Height="350" Width="525">
<Grid>
</Grid>
</Window>
但我得到同樣的錯誤。
我試過,沒有運氣,所有的以下內容:
- 重新安裝Visual Studio 2010的
- 重新安裝.NET
- 刪除在Visual Studio目錄(\用戶\ [用戶] \文件\ Visual Studio 2010)。
我該怎麼辦才能修復它?
我都試過「.Net框架4" 和」 .Net框架4客戶端配置文件」。沒有運氣 :( – Reimund 2010-12-06 08:03:49