Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix missing method exception in Xamarin.Forms PCL Android mobile app

I'm getting a System.MissingMethodException error after updating Xamarin.Forms package for Android Mobile App. In MainActivity.cs line #22:

LoadApplication (new App ());

Application Output:

[] Missing method Android.Runtime.JNIEnv::StartCreateInstance(Type,string,JValue*) in assembly Mono.Android.dll, referenced in assembly /storage/emulated/0/Android/data/XAMLDataBindings_PCL.Droid/files/.__override__/Xamarin.Android.Support.v4.dll

I have tried Clean & Rebuild All as mentioned on the Xamarin forum but still not working. The project works for iOS so not sure why Android project won't run now?

like image 652
David Douglas Avatar asked Apr 28 '15 15:04

David Douglas


1 Answers

I also had the same problem today. I removed all Xamarin.* NuGets from the Android project, re-installed Xamarin.Forms and it fetched the previous versions of Xamarin.Android.* NuGets, which is 21.0.3.0. All is working fine now. I am waiting for a fix.

like image 67
Dimitris Tavlikos Avatar answered Sep 18 '22 18:09

Dimitris Tavlikos