所以我在Windows 8上使用VS12,并且攻击ContosoCookbook代码以制作不同的应用程序.我正在尝试设置一个"MainMenu.xaml"页面,我有:
<CollectionViewSource
x:Name="groupedItemsViewSource"
Source="{Binding Groups}"
IsSourceGrouped="true"
ItemsPath="TopItems"
d:Source="{Binding AllGroups, Source={d:DesignInstance Type=data:FlashCardDataSource, IsDesignTimeCreatable=True}}"/>
Run Code Online (Sandbox Code Playgroud)
我得到的错误是:名称"FlashCardDataSource"在命名空间"using:FlashCards.Data"中不存在.
......但我不明白它是怎么回事.我从哪里开始寻找?我是XAML的新手.
-Ken
ger*_*ude 19
如果没有别的可能,请注释使用命名空间的行,重建,然后再次构建完整的项目.
我也尝试重建项目,重新打开Visual Studio.什么都没有帮助.我终于评论说xaml,重建了这个项目,没有注释xaml,终于工作了!奇怪的问题.
通常,此错误是由以下之一引起的: