我收到了一个奇怪的无效播放异常,我怀疑是由于命名空间不匹配,但我不知道在哪里。
异常消息是:
其他信息:无法投射类型' FishTracker.FishTracker'输入' FishTracker.Application'。
现在已经出现这种情况,因为我决定从头开始重建一个应用程序,发现了一个至关重要的缺陷。它是一个wpf应用程序。
主要的xaml读起来像这样:
<Application x:Class="FishTracker"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:FishTracker"
StartupUri="Views\MainRibbonView.xaml">
<Application.Resources>
</Application.Resources>
在后面的vb文件中定义如下:
Public Partial Class FishTracker
Inherits Windows.Application
在应用程序设置中,Assembley名称为FishTracker,RootNamespace为FishTracker。
就我看到的所有内容都匹配而言,当它运行时,MyWpfExtension.vb抛出了无效的广播异常,但它仍然失败(我甚至无法在解决方案中看到它)。
欢迎任何想法。