不能为Visual Studio启动Android模拟器

本文关键字:Android 模拟器 启动 Studio Visual 不能 | 更新日期: 2023-09-27 18:06:26

我试着用微软论坛提供的几个修复程序来修复这个问题,但没有任何效果,我不明白一些事情。

我试图启动一个测试Xamarin代码,使其在Android配置文件上运行,但当我试图安装它时,它停留在复制。vhd文件并创建一个虚拟机。这里。

然后提示输入admin并重试。它失败了,给我这个日志文件:

0> 9/9/2016 10:11:43 PM : [Informational] ===== Session Started =====
1> 9/9/2016 10:11:43 PM : [Informational] Emulator manager version: 1.1.622.2
1> 9/9/2016 10:11:43 PM : [Informational] Emulator manager plugin version: 1.1.622.2
1> 9/9/2016 10:11:43 PM : [Informational] Microsoft Windows NT 10.0.14393.0 Windows 10 Pro
1> 9/9/2016 10:11:43 PM : [Informational] Virtualization type: UnknownOrNotVirtual
1> 9/9/2016 10:11:43 PM : [Informational] Virtualization Version: alaska - 1072009
1> 9/9/2016 10:11:43 PM : [Informational] Virtualization Serial Number: to be filled by o.e.m.
1> 9/9/2016 10:11:43 PM : [Informational] Virtualization Product: z97 killer
1> 9/9/2016 10:11:43 PM : [Informational] Display Adapter 0: Name: NVIDIA GeForce GTX 970, Version: 21.21.13.7270
2> 9/9/2016 10:11:43 PM : [Informational] Reinitializing installed profiles.
2> 9/9/2016 10:11:43 PM : [Informational] Installed profiles initialized. Devices: 1 Platforms: 2
2> 9/9/2016 10:11:43 PM : [Informational] Reinitializing installable profiles.
2> 9/9/2016 10:11:45 PM : [Informational] Installable profiles initialized. Devices: 38 Platforms: 5
3> 9/9/2016 10:12:06 PM : [Informational] Waiting to uninstall device...
3> 9/9/2016 10:12:06 PM : [Informational] Uninstalling Device: 10.1" Marshmallow (6.0.0) XHDPI Tablet
3> 9/9/2016 10:12:06 PM : [Informational] Uninstalling virtual machine for 10.1" Marshmallow (6.0.0) XHDPI Tablet
3> 9/9/2016 10:12:06 PM : [Informational] Removing device files
3> 9/9/2016 10:12:06 PM : [Informational] Uninstall complete
2> 9/9/2016 10:12:06 PM : [Informational] Reinitializing installed profiles.
2> 9/9/2016 10:12:06 PM : [Informational] Installed profiles initialized. Devices: 0 Platforms: 2
4> 9/9/2016 10:12:08 PM : [Informational] Waiting to install device...
4> 9/9/2016 10:12:08 PM : [Informational] Installing Device: 5.7" Marshmallow (6.0.0) XHDPI Phone , Version: 1.0.60404.1
4> 9/9/2016 10:12:09 PM : [Informational] Creating device configuration
2> 9/9/2016 10:12:09 PM : [Informational] Reinitializing installed profiles.
2> 9/9/2016 10:12:09 PM : [Informational] Installed profiles initialized. Devices: 1 Platforms: 2
4> 9/9/2016 10:12:10 PM : [Informational] Copying .vhd files and creating virtual machine
4> 9/9/2016 10:14:12 PM : [Informational] Waiting to uninstall device...
4> 9/9/2016 10:14:12 PM : [Informational] Uninstalling Device: 5.7" Marshmallow (6.0.0) XHDPI Phone
4> 9/9/2016 10:14:12 PM : [Informational] Uninstalling virtual machine for 5.7" Marshmallow (6.0.0) XHDPI Phone
4> 9/9/2016 10:14:13 PM : [Informational] Removing device files
4> 9/9/2016 10:14:13 PM : [Informational] Uninstall complete
2> 9/9/2016 10:14:13 PM : [Informational] Reinitializing installed profiles.
2> 9/9/2016 10:14:13 PM : [Informational] Installed profiles initialized. Devices: 0 Platforms: 2
4> 9/9/2016 10:14:14 PM : [Informational] Waiting to install device...
4> 9/9/2016 10:14:14 PM : [Informational] Installing Device: 5.7" Marshmallow (6.0.0) XHDPI Phone , Version: 1.0.60404.1
4> 9/9/2016 10:14:14 PM : [Informational] Creating device configuration
2> 9/9/2016 10:14:14 PM : [Informational] Reinitializing installed profiles.
2> 9/9/2016 10:14:14 PM : [Informational] Installed profiles initialized. Devices: 1 Platforms: 2
4> 9/9/2016 10:14:15 PM : [Informational] Copying .vhd files and creating virtual machine
4> 9/9/2016 10:15:27 PM : [Critical] An internal virtual network switch is required for emulated devices to run.
4> 9/9/2016 10:15:27 PM : [Critical] XDE Path: C:'Program Files (x86)'Microsoft XDE'10.0.10586.0'xde.exe
4> 9/9/2016 10:15:27 PM : [Critical] XDE Arguments: /sku Android /displayName "VS Emulator 5.7'" Marshmallow (6.0.0) XHDPI Phone" /memSize 3072 /diagonalSize 5.7 /video "1440x2560" /vhd "C:'Users'lbthe'AppData'Local'Microsoft'VisualStudioEmulator'Android'Containers'Local'Devices'vhd'5.7_Marshmallow_(6.0.0)_XHDPI_Phone'image.vhd" /name "VS Emulator 5.7-inch Marshmallow (6.0.0) XHDPI Phone.lbthe" /noStart /silent
4> 9/9/2016 10:15:27 PM : [Critical] XDE Exit Code: CouldntCreateInternalSwitch (16)

我读到我应该创建一个内部开关和一个外部开关。我可以成功地做一个内部的,但当我试图做一个外部的发生。

使用Windows 10 Pro,如果这对任何有用的,如果你需要更多的信息,我很乐意提供它。

不能为Visual Studio启动Android模拟器

我以前遇到过这个问题。您总是可以重新检查是否将开发人员模式设置为true。去你的设置->更新->然后开发者确保开发者模式是打开的。然后,您还需要确保您的计算机通过BIOS启用Hyper-V,有时它们被关闭。如果你没有Hyper-V功能,那么你几乎没有机会使用模拟器。你只能选择次优选择了。在测试android手机上安装。

此链接可能有用

https://blogs.msdn.microsoft.com/visualstudioalm/2015/07/20/using-the-visual-studio-emulator-for-android-from-android-studio-or-eclipse-with-adt/

我以前有这个问题,我需要重新安装Windows