Build Your First Android App with Visual Studio 2019 and Xamarin

Play Build Your First Android App with Visual Studio 2019 and Xamarin
Sign in to queue

Description

In this video, I'll show you the steps to build your first Android application in Visual Studio 2019 with C#, .NET, and Xamarin. We will see how to build a basic app and then compile and deploy using Android emulators.

Show Links:

Useful Links:

Embed

Download

The Discussion

  • User profile image
    David Martin

    Need someone to test this Visual Studio 2019 Tutorial

    Does not work when I try it. it's only a 4 minute tutorial. I must be missing something.

    I will describe my environment. Windows 10 Pro. Visual Studio 2019 Community

    I chose the single page template.

  • User profile image
    David Martin

    I followed the tutorial exactly. Tried to run. Got this error message:

    1> No way to resolve conflict between "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" and "mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e". Choosing "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" arbitrarily.

    Please resolve.

  • User profile image
    soullessEOL

    The title is not clear enough to state that this is with xamarin forms which approach is different from xamarin android.

  • User profile image
    Giddar
    Does not work.

    Just installed latest version of VS2019 (v16.1.5)
    Noted also that I got a different version of the nuget packages Xamarin.Essentials (1.1.0) and Xamarin.Forms (4.0.0.425677)

    Output when I build:
    1>------ Rebuild All started: Project: App1, Configuration: Debug Any CPU ------
    1>C:\Program Files\dotnet\sdk\3.0.100-preview5-011568\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.RuntimeIdentifierInference.targets(157,5): message NETSDK1057: You are using a preview version of .NET Core. See: https://aka.ms/dotnet-core-preview
    1>App1 -> C:\VisualStudio\App1\App1\App1\bin\Debug\netstandard2.0\App1.dll
    2>------ Rebuild All started: Project: App1.Android, Configuration: Debug Any CPU ------
    2> App1.Android -> C:\VisualStudio\App1\App1\App1.Android\bin\Debug\App1.Android.dll
    2> No way to resolve conflict between "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" and "mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e". Choosing "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" arbitrarily.
    2>C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2664,3): error MSB6006: "javac.exe" exited with code 3.
    ========== Rebuild All: 1 succeeded, 1 failed, 0 skipped ==========

    Tried updating nuget Xamarin.Forms to version (4.1.0.555618) with the same result.

    Tried searching the web for "javac exited with code 3" but found no luck.
  • User profile image
    scottjohnso​nllc
    I liked your video, but when I try to create the android emulator the Processor and OS are blank. Any suggestion? Thanks
  • User profile image
    Cami

    I installed VS 2019 Ent and when I try to create an Android emulator I get the message:

    Could not start emulator

    Could not launch the emulator.
    Please file an issue by choosing "Report a Problem" in the Help menu, and attach your logs.
    Error message: "An attempt was made to load a program with an incorrect format."

    This makes it hard to create any mobile apps. Any insight to fixing this would be greatly appreciated. The video made it seem so simple with Xamarin.

  • User profile image
    Jules

    My VS2019 experience is no where as good as this.
    Android Emulators fail to boot up, hang, (wait tem minutes, still not booting!) random and uninformative Android emulators.
    "starting Emulator", "Emulator xxxx cannot be started", "runtime checks completed", NuGet package restore cancelled" "build has ben cancelled"

    I do have Hyper V working OK, but Android development and Emulation is still a hit and miss affair on VS2019.

    Horrible

Add Your 2 Cents