简体   繁体   English

VS 2015 - WP8 - “指定的通信资源(端口)已被其他应用程序使用。”

[英]VS 2015 - WP8 - “A specified communication resource (port) is already in use by another application.”

I have a solution with the followings: 我有以下解决方案:

  • WP8 project WP8项目
  • WP8.1 project WP8.1项目
  • UWP project UWP项目
  • Xamarin.Android project Xamarin.Android项目
  • PCLs PCLS

I have both VS2013 with Update 5 and VS2015 with Update 1 installed on my PC. 我在我的电脑上安装了VS2013和Update 5以及VS2015和Update 1
The OS is Windows 10.0.10586.318 . 操作系统是Windows 10.0.10586.318
It is a fresh install as I reinstalled the whole PC due to other reasons. 由于其他原因我重新安装了整个PC,这是一个全新的安装。

Note: Before the reinstall I used VS2015 with Update 2 (and VS2013 with Update 5) but the same issue occured. 注意:在重新安装之前,我使用VS2015和Update 2(和VS2013和Update 5),但是出现了同样的问题。 So installing Update 2 does not seem to be a solution. 因此,安装Update 2似乎不是一个解决方案。

In the Configuration Manager the Android, WP8 and WP8.1 projects are checked in "Deploy" column. 在Configuration Manager中,将在“Deploy”列中检查Android,WP8和WP8.1项目。

I would like to use the WP8 emulator to debug my WP8 project. 我想使用WP8模拟器来调试我的WP8项目。

  • In VS2013 it works as expected. 在VS2013中它按预期工作。
  • In VS2015 I can debug the WP8 app in the WP8.1 emulator but not in the WP8 emulator. 在VS2015中,我可以在WP8.1仿真器中调试WP8应用程序,但不能在WP8仿真器中调试。
    The deploy is successful but the following error message appears: 部署成功但出现以下错误消息:

A specified communication resource (port) is already in use by another application. 指定的通信资源(端口)已被另一个应用程序使用。
In the statusbar: Launching TaskHost.exe failed. 在状态栏中: 启动TaskHost.exe失败。

In the output window: 在输出窗口中:

1>------ Build started: Project: X.Y.WP8, Configuration: Debug Any CPU ------
1>  X.Y.WP8 -> D:\Programs\DotNET\Visual Studio 2015 Projects\Y\X.Y.WP8\Bin\Debug\X.Y.WP8.dll
1>  Begin application manifest generation
1>  No changes detected. Application manifest file is up to date
1>  Begin Xap packaging
1>  Creating file X.Y.WP8_Debug_AnyCPU.xap
1>  Adding .... (lots of files)
1>  Xap packaging completed successfully
2>------ Deploy started: Project: X.Y.WP8, Configuration: Debug Any CPU ------
2>Deploying D:\Programs\DotNET\Visual Studio 2015 Projects\Y\X.Y.WP8\Bin\Debug\X.Y.WP8_Debug_AnyCPU.xap...
2>Connecting to Emulator WVGA 512MB...
2>The application is already installed on the device. Checking if an incremental deployment is possible...
2>Doing full deployment as project was cleaned and rebuilt...
2>Uninstalling the application...
2>Installing the application...
2>Updating information related to installed files...
2>Deployment of D:\Programs\DotNET\Visual Studio 2015 Projects\Y\X.Y.WP8\Bin\Debug\X.Y.WP8_Debug_AnyCPU.xap succeeded.
========== Build: 1 succeeded, 0 failed, 3 up-to-date, 0 skipped ==========
========== Deploy: 1 succeeded, 0 failed, 0 skipped ==========

When I try to start debugging only one instance of VS2015 is running and nothing else. 当我尝试开始调试时,只有一个VS2015实例正在运行,没有别的。

I read lots of answers regarding same or similar issues but none of them worked. 我读了很多关于相同或类似问题的答案,但没有一个有效。

  • Fortunately I don't have any non-Latin char in my user name. 幸运的是,我的用户名中没有任何非拉丁字符。
  • Tried deleting the contents of ...\\AppData\\Local\\Microsoft\\Phone Tools\\CoreCon\\ folder. 尝试删除...\\AppData\\Local\\Microsoft\\Phone Tools\\CoreCon\\文件夹的内容。
  • Restarted VS2015. 重启VS2015。
  • etc. 等等

What does VS2013 know what VS2015 does not? 什么VS2013知道什么是VS2015?

As a workaround, for the WP8 project: 作为解决方法,对于WP8项目:

  • I can use VS2013 to use the WP8 emulator. 我可以使用VS2013来使用WP8模拟器。
  • I can use the WP8.1 emulator in VS2015. 我可以在VS2015中使用WP8.1仿真器。

But the goal is to be able to use WP8 emulator in VS2015. 但目标是能够在VS2015中使用WP8仿真器。

在VS2015中使用WP8.1仿真器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM