在WebViewExtension类型中找不到可附加属性HtmlSource

时间:2015-08-29 06:04:24

标签: xaml mvvm uwp callisto

我在Callisto找到了WebView的WebViewExtension方法。这种方法在Windows 8.1应用程序中运行良好,现在当我尝试在通用Windows应用程序中使用时,它给了我这个错误。

  

在类型中找不到可附加属性HtmlSource   WebViewExtension

我在用户控件中使用此语法。

<WebView x:Name="ContentView"
Margin="15,10,10,10"
callisto:WebViewExtension.HtmlSource="{Binding SelectedFeedItem.Content}"/>

WebViewExtension方法的来源是here

更新: 只是为了确保我没有弄乱我的xmlns声明 1.我有一个公共文件夹common,在里面我有一个名为Callisto.cs的文件,复制了相同的来源,没有变化。
2.在我的xmlns:声明中我有xmlns:callisto="Myrssapp.Win10.Common" 下面是图像。 enter image description here

1 个答案:

答案 0 :(得分:0)

我发现了我的问题而且我不知道为什么它在Win 8中有用,或者我必须改变一些东西。错误发生在xmlns:语句中。

而不是
xmlns:callisto="Myrssapp.Win10.Common"

它应该是 xmlns:callisto="using:Myrssapp.Win10.Common"
我错过了using关键字。