-
Notifications
You must be signed in to change notification settings - Fork 492
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using Microsoft.Azure.Devices.Client in Xamarin.Forms Android project #434
Comments
This is a known Xamarin.Android issue: dotnet/android#1162 Also listed as an issue in this repo: #373 Try replacing the contents of |
I tried that, and that doesn't work. |
Thanks @craylward and @ChakraSpice . We are aware of several Xamarin issues and we will need to spend more time investigating. |
We have updated some Xamarin Android samples in our repository which implement send & receive messages. Could you please try with those and let us know if it helps! Thanks! |
@ChakraSpice - Could you please try out using the latest samples and let us know if that helps. In case you face further issues, please open another GitHub issue. Thanks! |
I have the same issue when trying to deploy the application on Android emulator. I tried your samples but I get the old error message. Which sample do you exactly mean? |
@abhipsaMisra the issue is resolved after upgrading Visual Studio 2017 to version 15.7.5. Thanks! |
I made a Xamarin.Forms project. .NET Standard is the code sharing strategy. Using Visual Studio, Windows 10.
I am able to send messages to the IoT Hub on the UWP app, but not from Android. Build succeeds, but it doesn't deploy right on the device.
Description of the issue:
I installed 1.7.0 version of Microsoft.Azure.Devices.Client NuGet package.
Code sample exhibiting the issue:
}
These are some of the entries when I build the project:
Ignoring C:\Users\User.nuget\packages\system.runtime.compilerservices.unsafe\4.4.0\ref
And after the deployment fails I see this:
03-29 09:59:37.727 D/Mono (24241): Assembly Loader probing location: 'System.Runtime.CompilerServices.Unsafe'.
03-29 09:59:37.727 F/monodroid-assembly(24241): Could not load assembly 'System.Runtime.CompilerServices.Unsafe' during startup registration.
03-29 09:59:37.727 F/monodroid-assembly(24241): This might be due to an invalid debug installation.
03-29 09:59:37.727 F/monodroid-assembly(24241): A common cause is to 'adb install' the app directly instead of doing from the IDE.
How to resolve this issue? Is it even possible to use Microsoft.Azure.Devices.Client for Android devices?
I tried various linker options but to no avail.
Issue sample repo
Check out the repo with the sample code: https://github.com/ChakraSpice/Xamarin-IoT-Android-Issue-Sample (use your own connection string)
The text was updated successfully, but these errors were encountered: