EventToCommand缺少Windows Phone应用程序

我正在使用MVVM Light构建Windows Phone 8应用程序。 到现在为止还挺好。 但是,当我使用EventToCommand时,我会遇到多个错误。 一个类似的问题是,在为SL5迁移到v4时,EventToCommand无法正常工作 ,但遗憾的是它无法解决我的问题。 它会自动添加以下参考:

xmlns:command1="http://www.galasoft.ch/mvvmlight" 

我收到的错误:

命名空间“EventToCommand”在命名空间“clr-namespace:GalaSoft.MvvmLight.Command; assembly = GalaSoft.MvvmLight.WP8”中不存在

找不到类型’command:EventToCommand’。 validation您是否缺少程序集引用,并且已构建所有引用的程序集。

XML命名空间’clr-namespace中不存在标记’EventToCommand’:GalaSoft.MvvmLight.Command; assembly = GalaSoft.MvvmLight.WP8′

如果我遗漏任何东西或做错事,请告诉我。

谢谢

这是正确的xmlns(您在程序集名称中缺少Extras ):

 xmlns:Command="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WP8" 

替换为

 xmlns:command1="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WP8" 

使用最新版本,命令移至平台程序集:

 xmlns:command="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Platform"