Skip to content
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

Does not run in Android emulator #50

Closed
jfacoustic opened this issue Dec 21, 2020 · 2 comments
Closed

Does not run in Android emulator #50

jfacoustic opened this issue Dec 21, 2020 · 2 comments

Comments

@jfacoustic
Copy link

Both HelloAndroid and HelloForms successfully build, but they don't attach to my android emulator. The output for dotnet build HelloForms/HelloForms.csproj -t:Run -p:TargetFramework=net6.0-android is

Microsoft (R) Build Engine version 16.9.0-preview-20561-01+56ab63409 for .NET
Copyright (C) Microsoft Corporation. All rights reserved.

  Determining projects to restore...
  Restored C:\Users\joshua\Documents\net6-samples\HelloForms\HelloForms.csproj (in 1.03 min).
  You are using a preview version of .NET. See: https://aka.ms/dotnet-core-preview
  HelloForms -> C:\Users\joshua\Documents\net6-samples\HelloForms\bin\Debug\net6.0-android\HelloForms.dll

Build succeeded.
    0 Warning(s)
    0 Error(s)

Time Elapsed 00:02:14.82

Am I missing a step?

@jonathanpeppers
Copy link
Member

@jfacoustic sorry for the delay, everyone is off for the holidays. Your command should work did you try running adb devices to see if your emulator is connected? If it shows no devices restart the emulator, just using the device manager in Visual Studio with the current Xamarin workload.

The Run target should work if adb is connected to a single device or emulator.

@jonathanpeppers
Copy link
Member

Try the latest builds on main for Preview 2, and let us know if you run into any issues, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants