Community
Topic: Xamarin component
Unhandled Exception (SOLVED)
While trying to run https://github.com/REDECODE/PikkartSample this code I am recieving an unhandled exception as
08-18 02:24:18.616 E/mono ( 5166): Unhandled Exception:
08-18 02:24:18.616 E/mono ( 5166): System.TypeLoadException: VTable setup of type PikkartSample.Droid.MainActivity failed
08-18 02:24:18.616 E/mono ( 5166): at (wrapper managed-to-native) System.RuntimeType:GetMethodsByName_native (System.RuntimeType,intptr,System.Reflection.BindingFlags,bool)
08-18 02:24:18.616 E/mono ( 5166): at System.RuntimeType.GetMethodsByName (System.String name, System.Reflection.BindingFlags bindingAttr, System.Boolean ignoreCase, System.RuntimeType reflectedType) [0x0001b] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.616 E/mono ( 5166): at System.RuntimeType.GetMethodCandidates (System.String name, System.Reflection.BindingFlags bindingAttr, System.Reflection.CallingConventions callConv, System.Type[] types, System.Boolean allowPrefixLookup) [0x00010] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.616 E/mono ( 5166): at System.RuntimeType.GetMethodImpl (System.String name, System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, System.Reflection.CallingConventions callConv, System.Type[] types, System.Reflection.ParameterModifier[] modifiers) [0x00000] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.616 E/mono ( 5166): at System.Type.GetMethod (System.String name, System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, System.Type[] types, System.Reflection.ParameterModifier[] modifiers) [0x00043] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.616 E/mono ( 5166): at System.Delegate.GetCandidateMethod (System.Type type, System.Type target, System.String method, System.Reflection.BindingFlags bflags, System.Boolean ignoreCase, System.Boolean throwOnBindFailure) [0x00092] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.616 E/mono ( 5166): at System.Delegate.CreateDelegate (System.Type type, System.Type target, System.String method, System.Boolean ignoreCase, System.Boolean throwOnBindFailure) [0x00014] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.616 E/mono ( 5166): at System.Delegate.CreateDelegate (System.Type type, System.Type target, System.String method) [0x00000] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.616 E/mono ( 5166): at Android.Runtime.JNIEnv.RegisterJniNatives (System.IntPtr typeName_ptr, System.Int32 typeName_len, System.IntPtr jniClass, System.IntPtr methods_ptr, System.Int32 methods_len) [0x00209] in <61dabd3f0b0446bc8b570d6071d995d7>:0
08-18 02:24:18.618 E/mono-rt ( 5166): [ERROR] FATAL UNHANDLED EXCEPTION: System.TypeLoadException: VTable setup of type PikkartSample.Droid.MainActivity failed
08-18 02:24:18.618 E/mono-rt ( 5166): at (wrapper managed-to-native) System.RuntimeType:GetMethodsByName_native (System.RuntimeType,intptr,System.Reflection.BindingFlags,bool)
08-18 02:24:18.618 E/mono-rt ( 5166): at System.RuntimeType.GetMethodsByName (System.String name, System.Reflection.BindingFlags bindingAttr, System.Boolean ignoreCase, System.RuntimeType reflectedType) [0x0001b] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.618 E/mono-rt ( 5166): at System.RuntimeType.GetMethodCandidates (System.String name, System.Reflection.BindingFlags bindingAttr, System.Reflection.CallingConventions callConv, System.Type[] types, System.Boolean allowPrefixLookup) [0x00010] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.618 E/mono-rt ( 5166): at System.RuntimeType.GetMethodImpl (System.String name, System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, System.Reflection.CallingConventions callConv, System.Type[] types, System.Reflection.ParameterModifier[] modifiers) [0x00000] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.618 E/mono-rt ( 5166): at System.Type.GetMethod (System.String name, System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, System.Type[] types, System.Reflection.ParameterModifier[] modifiers) [0x00043] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.618 E/mono-rt ( 5166): at System.Delegate.GetCandidateMethod (System.Type type, System.Type target, System.String method, System.Reflection.BindingFlags bflags, System.Boolean ignoreCase, System.Boolean throwOnBindFailure) [0x00092] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.618 E/mono-rt ( 5166): at System.Delegate.CreateDelegate (System.Type type, System.Type target, System.String method, System.Boolean ignoreCase, System.Boolean throwOnBindFailure) [0x00014] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.618 E/mono-rt ( 5166): at System.Delegate.CreateDelegate (System.Type type, System.Type target, System.String method) [0x00000] in <3fd174ff54b146228c505f23cf75ce71>:0
08-18 02:24:18.618 E/mono-rt ( 5166): at Android.Runtime.JNIEnv.RegisterJniNatives (System.IntPtr typeName_ptr, System.Int32 typeName_len, System.IntPtr jniClass, System.IntPtr methods_ptr, System.Int32 methods_len) [0x00209] in <61dabd3f0b0446bc8b570d6071d995d7>:0
Hi, We have not yet provided an official tutorial for xamarin android. It is possible that the repository you have linked contains errors, even if we were unable to reproduce them in our tests.
Anyway we advise you to wait for the official tutorial to be released or try converting the tutorial written in java at this link.
Best,
Hi,
we publish many Xamarin tutorials for Android.
Please check the tutorial and samples section, hope it could be usefully for your development.