Problem
If I link Windows Phone to a PC through Zune software, and then connect to Windows Mobile. If you want to use Visual Studio to debug Windows Mobile, the following error message is displayed.
5> all attempts to connect to the deployment target at Port 5655 have failed. Addresses attempted:
5> 127.0.0.1.
5> the device security configuration may have disallowed the connection. ensure that you have the appropriate certificates on your deviceForDevelopment. Review Your SDK documentationForProper Security SettingsForConnectingThisDevice.
5>
5> connect to device failed.
I think Zune software and ActiveSync use the same technology, such as socket, and the same port number.
Solution
Connect to Windows Mobile first, and then connect to Windows Phone to debug Windows MobileProgram. In addition, I tried to debug Windows Phone programs at the same time. The sequence is critical. However, the following error message is prompted when I restart Windows Mobile. One mountain cannot hide two tigers.
Unable to Start Program 'windowsmobileprogram.exe'
An existing connection was forcibly closed by the remote host.