Is there any way I can create executable or library compatible to Android using Xamarin

MADBMADB USMember

I have code in C# core to provision, register IoT devices to IoT hub Azure using Azure C# sdk

I would like to use that to work in Android Device.

Is there any way I can build executable and libraries compatible to Android using Xamarin

Tagged:

Answers

  • JarvanJarvan Member, Xamarin Team Xamurai

    Try to incorporate Java libraries into your Xamarin.Android application by creating a Bindings Library.

    Xamarin.Android offers two ways to use these third-party libraries:

    • Create a Bindings Library that automatically wraps the library with C# wrappers so you can invoke Java code via C# calls.

    • Use the Java Native Interface (JNI) to invoke calls in Java library code directly. JNI is a programming framework that enables Java code to call and be called by native applications or libraries.

    Check the tutorial:
    https://docs.microsoft.com/en-us/xamarin/android/platform/binding-java-library/

Sign In or Register to comment.