sameerkapps / SecureStorage

119 stars 32 forks source link

Exception thrown: Java.Lang.NoSuchMethodError #35

Open mcus01 opened 6 years ago

mcus01 commented 6 years ago

Hi!

I'm getting the following error in my Xamarin Forms application: [ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: The type initializer for 'Plugin.SecureStorage.SecureStorageImplementation' threw an exception. ---> Java.Lang.NoSuchMethodError: no static method "Landroid/os/Build;.getSerial()Ljava/lang/String;"

This is thrown when I try to use the SetValue method: CrossSecureStorage.Current.SetValue("test", "123");

I'm using SecureStorage version 2.0.1 (although, I'm also getting the problem in version 2.0).

Any clues? Thanks!

sameerkapps commented 6 years ago

Are you compiling against SDK 26 (i.e. Android 8.0)?

Softtinn commented 6 years ago

We're using an emulator with Android 7.0 (API 24).

vikram-ma commented 6 years ago

I am compiling against compiling against SDK 26 (i.e. Android 8.0), I am getting same exception, using version 2.0.1