发生XamlParseException - 未实现方法或操作 [英] XamlParseException occurred -- The method or operation is not implemented

查看:156
本文介绍了发生XamlParseException - 未实现方法或操作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是WPF的新手,当我使用MVVM和Prism编写我的第一个WPF应用程序时,遇到异常,异常发生在以下代码中:

I'am a newer to WPF, when i use MVVM and Prism to write my first WPF application, i meet an exception, the exception happend from the below code:

的xmlns:I =" HTTP://schemas.microsoft.com/expression/2010/interactivity"

xmlns:ei = http://schemas.microsoft.com/expression / 2010 / interaction

xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
xmlns:ei=http://schemas.microsoft.com/expression/2010/interactions

< Button Command =" {Binding}"含量="登录" Grid.Row = QUOT 1 QUOT; IsEnabled =" {Binding Path = IsLoginButtonEnabled}">

< i:Interaction.Triggers>

< i:EventTrigger EventName =" Click"> ; $
< ei:CallMethodAction TargetObject =" {Binding}"方法名= QUOT;为LoginEvent" /> -
此行有一个异常"发生了XamlParseException"该方法或操作未实施。


< / i:EventTrigger>

< / i:Interaction.Triggers>

< / Button>

<Button Command="{Binding }" Content="Login" Grid.Row="1" IsEnabled="{Binding Path=IsLoginButtonEnabled}">
<i:Interaction.Triggers>
<i:EventTrigger EventName="Click">
<ei:CallMethodAction TargetObject="{Binding}" MethodName="LoginEvent"/> -- This line have an exception "XamlParseException occurred" The method or operation is not implemented.
</i:EventTrigger>
</i:Interaction.Triggers>
</Button>

我使用Prism和MEF将viewmodel注入此视图,并使用"LoginEvent"和"LoginEvent"。存在于viewmodel类中LoginViewModel

I use Prism and MEF to inject viewmodel to this view, and the "LoginEvent" is exists in viewmodel class LoginViewModel

public void Login()

{

//无事可做。

public void Login()
{
//Nothing to do.

}

非常奇怪的是,我甚至无法使用try ... catch ...在LoginView.cs文件中捕获此异常:

the very strange thing is that i can not even use try ... catch... to catch this exception like this in the LoginView.cs file:

尝试
{

InitializeComponent();

}

catch(例外e)

{

InitializeComponent();
}
catch (Exception e)
{

}

以前有没有人见过这个,等你的帮助!!!!

Is there anybody met this before, waitting for your help!!!!

推荐答案

您好Itigoo,

Hi Itigoo,

因为您的问题是关于Expression SDK ,我已将此主题移至Expression Forum以获得更好的支持。

Since you question is about Expression SDK, I have moved this thread to Expression Forum for better support.

祝你好运,


这篇关于发生XamlParseException - 未实现方法或操作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆