Compact Framework - Invalid URI: The hostname could not be parsed
I am writing a Compact Framework 3.5 application for a Windows mobile device. In this application, I am using a web service to sync with our database. However, whenever I try to make a web service call from a device or emulator, I get the following error: Invalid URI: The hostname could not be parsed. I am connected to the network via R-NDIS. The service is running on my development machine right now and I can actually navigate to the asmx page via Pocket IE. What am I missing?
Thank!
+2
source to share
2 answers
You might not pick up the proxy that IE uses, or Pocket IE might display a cached version of the ASMX page (and therefore can't actually get it). None of these are likely your problem.
Update : Try putting it in your app config file:
<configuration>
<system.net>
<defaultProxy>
<proxy autoDetect="true" />
</defaultProxy>
</system.net>
</configuration>
0
source to share