我有一个使用 Caliburn.Micro 的 wpf 应用程序。我有一个视图 MyView:
<UserControl x:Class="ReferenceMaintenanceWorkspace.MyView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
>
<UserControl.Resources>
</UserControl.Resources>
<TabControl x:Name="Items" >
</TabControl>
我还有 MyViewModel:
using System.ComponentModel.Composition;
namespace ReferenceMaintenanceWorkspace
{
[Export(typeof(MyViewModel))]
public class MyViewModel
{
public MyViewModel()
{
base.DisplayName = "Reference Maintenance";
}
由于某种原因,我在选项卡控件上收到以下消息:
找不到 ReferenceMaintenanceWorkspace.MyViewModel 的视图。
您能解释一下为什么会发生这种情况吗?
谢谢。
只是为了将来,重命名类/包后也会发生这种情况,但在视图 xaml 文件“x:Class”中不会更新。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)