Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

EventToCommand Missing For Windows Phone App

I'm building Windows Phone 8 app using MVVM Light. So far, so good. However, when I used EventToCommand, I get multiple errors. One similar question is here EventToCommand not working when migrate to v4 for SL5, but sadly it doesn't solve my problem.! It automatically adds following reference:

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

Errors that I receive:

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

The type 'command:EventToCommand' was not found. Verify that you are not missing an assembly reference and that all referenced assemblies have been built.

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

Let me know if I'm missing anything or doing something wrong.

Thanks

like image 844
Mayur Tendulkar Avatar asked Oct 23 '13 18:10

Mayur Tendulkar


2 Answers

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

xmlns:Command="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WP8"
like image 95
Olivier Payen Avatar answered Oct 18 '22 04:10

Olivier Payen


Replace it with

xmlns:command1="clr-namespace:GalaSoft.MvvmLight.Command;assembly=GalaSoft.MvvmLight.Extras.WP8"
like image 43
ScottIsAFool Avatar answered Oct 18 '22 05:10

ScottIsAFool