Why am I getting, “Unable to connect to the remote server”?

前端 未结 1 1754
野的像风
野的像风 2021-01-28 22:42

This err msg is the next one I get after resolving “NotSupportedException” as noted here

I don\'t even reach the break point in the server code (set on the first line of

相关标签:
1条回答
  • 2021-01-28 23:34

    The large problem I see here is the fact that you have localhost as your address. That's absolutely wrong. localhost means, effectively, "on the same machine as I am running" so unless you've somehow managed to get a async .NET 4.0 web service to run on your Windows CE device and your server code is running there, then this is most certainly not what you want.

    If you're running on an emulator, it's still wrong. The emulator is, for all intents and purposes, a separate machine.

    You must use the address of the server/PC where that web service is running. It must be a routable address, meaning if you're connected over USB then it's probably ppp_peer and not an IP address (well it resolves to a private address, but the name is easier to remember).

    0 讨论(0)
提交回复
热议问题