The tutorial N=5 of the N+1 days of MvvmCross builds fine in Xamarin Studio when downloaded. However, if I update the assemblies from 3.0.5 to 3.0.14, the iOS project no longer builds. The error has to do with these two lines:
set.Bind(button).To(vm => vm.MyCommand);
set.Bind(button2).To(vm => vm.GoSecondCommand);
The error message is as follows:
Cannot convert `lambda expression' to non-delegate type `string'
Has there been a change to the way this works? The object browser shows the correct method taking a Func<TSource, object>
but it seems that the compiler wants to use the string
version. The odd thing is that the two lines above it binding to regular properties work fine, but the ICommand
binded stuff fails.
Since N=5 was filmed, xamarin have added their own pcl support
As part of this support, you need to add a project reference for your Touch UI project to System.Windows.dll
in the Assemblies part of Add Reference.
This System.Windows assembly contains a type forwarding definition of ICommand - and this should clear your compilation error
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With