EventToCommand Error for Windows Phone Application

I am building a Windows Phone 8 application using MVVM Light. So far, so good. However, when I used EventToCommand, I get a few errors. One similar question here EventToCommand does not work when switching to v4 for SL5 , but, unfortunately, this does not solve my problem.! It automatically adds the following link:

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

Errors I get:

The name "EventToCommand" does not exist in the namespace "clr-namespace: GalaSoft.MvvmLight.Command; assembly = GalaSoft.MvvmLight.WP8"

Type: EventToCommand command not found. Make sure that you did not provide an assembly reference and that all reference assemblies have been created.

The tag 'EventToCommand' does not exist in the XML namespace 'clr-namespace: GalaSoft.MvvmLight.Command; assembly = GalaSoft.MvvmLight.WP8 '

Let me know if I miss something or something is wrong.

thanks

+7
c # windows-phone-8 mvvm-light
source share
3 answers

Here is the correct xmlns (you are missing Extras in the assembly name):

 xmlns:Command="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WP8" 
+8
source share

Replace it

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

In the latest version, the team moved to build the platform:

 xmlns:command="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Platform" 
+4
source share

All Articles