Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/333.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 错误:未找到与约束匹配的导出:_C#_Attributes_Mef_Waf - Fatal编程技术网

C# 错误:未找到与约束匹配的导出:

C# 错误:未找到与约束匹配的导出:,c#,attributes,mef,waf,C#,Attributes,Mef,Waf,我正在建立一个WAF项目。当我调试我的项目时。我遇到了这个问题 "The composition produced a single composition error. The root cause is provided below. Review the CompositionException.Errors property for more detailed information.\r\n\r\n1) No exports were found that match the c

我正在建立一个WAF项目。当我调试我的项目时。我遇到了这个问题

"The composition produced a single composition error. The root cause is provided below.
 Review the CompositionException.Errors property for more detailed information.\r\n\r\n1) 
 No exports were found that match the constraint: \n\tContractName\tWaf.InformationManager.OneNote.Modules.Applications.Views.INoteView\n\t
 RequiredTypeIdentity\tWaf.InformationManager.OneNote.Modules.Applications.Views.INoteView\r\n"
我怎么解决这个问题

我解决了我的问题(多亏了斯格拉西)
我没有创建NoteView.xaml(它实现INoteView并在类标题处添加[Export(typeof(INoteView)])

在实现
INoteView
的类上,您缺少了一个
[Export(typeof(INoteView)]
属性。是的。谢谢兄弟。它起作用了。我没有创建NoteView.xaml(它实现了INoteView,当然还有类标题处的[Export(typeof(INoteView)])。我将更新我的问题下面的问题。过去三天我一直在努力解决这个问题。你是我的救世主。非常感谢:)如果我回答了你的问题,你应该将我的答案标记为已接受。