fhunter

This question has been posted before. And I have followed all the answers I could find. Yet I still cannot connect to my WebService through a PocketPC application, neither through the emulator or the acutal device.

Here is the error I am getting:

'Strata.exe' (Managed): Loaded 'System.SR.dll', No symbols loaded.

A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll

A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll

A first chance exception of type 'System.UriFormatException' occurred in System.dll

This is where I stand.

The WebService is the default HelloWorld. I changed nothing.

When I include it as a reference in my POcketPC project, I use the computer name to reference to it. So the Service URL becomes:

http://lupus/WebServices/Service.asmx

I can access the WebService from Explorer with in the emulator and the actual device using:

http://lupus/WebServices/Service.asmx

I have tried running the app with the emulator cradled and uncradled. And the device of course is always cradled.

I have tried everything I can see online. Initially I could not access the service from explorer in the device or emulator. But know I can. So I don't know what else I need to do. Can someone help please

Thanks



Re: Device Emulator General Windows CE 5.0 MS Visual Studio 5.0 (WebRequest)

Mohit Gogia

Just confirming, if you are using proxy server, then you need to make sure your code configures it.

If this doesn't work, is it possible for you to post the code you are using. That may help us to find the problem, if any. Please let us know the exact configuration of your emulator also when you are able to repro it.

-Thanks,

Mohit





Re: Device Emulator General Windows CE 5.0 MS Visual Studio 5.0 (WebRequest)

Ilya Tumanov

Fairly common mistake with WS on devices is what developers are changing URL to "dynamic" and ¡°setting¡± it from configuration file. That works on desktop, but device offers no such service. That it, URL in configuration file is ignored and default URL is used. Please make sure default URL is correct or add some code to parse configuration file and set the URL accordingly.

From the error I would say your URL is bogus. It might be a good idea to print it out and see what it¡¯s set to right before WS is called.






Re: Device Emulator General Windows CE 5.0 MS Visual Studio 5.0 (WebRequest)

Apollo Strong

I got the exact same problem on a very very simple web access application. This happens on the Windows MObile 6 Professional Emulator running in Debug mode on MS Visual Studio 5.0

try

{

WebRequest req = WebRequest.Create("http://www.google.com/");

req.Timeout = 10000;

WebResponse rsp = req.GetResponse();

}

catch(Exception e)

{

Console.WriteLine(e.StackTrace); // Prints nothing...not reached at all.

}

Why the uri error Please help.

Thanks,

Apollo

====

'MobileClient.exe' (Managed): Loaded 'System.SR.dll', No symbols loaded.

A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll

A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll

A first chance exception of type 'System.UriFormatException' occurred in System.dll

The thread 0x7676ffce has exited with code 0 (0x0).

The thread 0x366a06e6 has exited with code 0 (0x0).

The thread 0x7676ffce has exited with code 0 (0x0).

The thread 0x5676fc82 has exited with code 0 (0x0).

The thread 0x9681f85e has exited with code 0 (0x0).





Re: Device Emulator General Windows CE 5.0 MS Visual Studio 5.0 (WebRequest)

Ilya Tumanov

Why do you believe there's an error What you see is simply debugger's output about some handled (e.g. not propagated to your application) exceptions.

There¡¯s a number of cases framework would handle exception, it¡¯s normal and there¡¯s nothing to be concerned with. You should only be concerned with exceptions which are propagated to your code.






Re: Device Emulator General Windows CE 5.0 MS Visual Studio 5.0 (WebRequest)

GSReddy

Hi Ilya Tumanov,

I am trying to connect to web service from pocket pc emulator 2003. I have custom configuration file and reading url from config file, I am able to see right url in execution / Debug mode. Although everthing looks fine, I am getting below error. I am able to browse webservice on desktop pc obviously. I am using decice mgr etc. Is there any other setting do I need to check

Error Msg:

- Err {"The remote name could not be resolved"} System.Exception {System.Net.WebException}
- [System.Net.WebException] {"The remote name could not be resolved"} System.Net.WebException
+ base {"The remote name could not be resolved"} System.InvalidOperationException {System.Net.WebException}
m_Response null System.Net.WebResponse
m_Status NameResolutionFailure System.Net.WebExceptionStatus
Response null System.Net.WebResponse
Status NameResolutionFailure System.Net.WebExceptionStatus
_HResult -2146233079 int
+ _innerException {"No such host is known"} System.Exception {System.Net.Sockets.SocketException}
_message "The remote name could not be resolved" string
+ _methodDescs {Dimensions:[15]} System.IntPtr[]
HResult -2146233079 int
+ InnerException {"No such host is known"} System.Exception {System.Net.Sockets.SocketException}
Message "The remote name could not be resolved" string
StackTrace "at System.Net.HttpWebRequest.finishGetResponse()\r\nat System.Net.HttpWebRequest.GetResponse()\r\nat System.Web.Services.Protocols.WebClientProtocol.GetWebResponse()\r\nat System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse()\r\nat System.Web.Services.Protocols.SoapHttpClientProtocol.doInvoke()\r\nat System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke()\r\nat InventCount_PDA_Part.InvDownUp.InvtService.GetInvt()\r\nat InventCount.FrmPartsList.menuItem4_Click()\r\nat System.Windows.Forms.MenuItem.OnClick()\r\nat System.Windows.Forms.Menu.ProcessMnuProc()\r\nat System.Windows.Forms.Form.WnProc()\r\nat System.Windows.Forms.Control._InternalWnProc()\r\nat Microsoft.AGL.Forms.EVL.EnterMainLoop()\r\nat System.Windows.Forms.Application.Run()\r\nat InventCount.FrmHome.Main()\r\n" string
"at System.Net.HttpWebRequest.finishGetResponse()\r\nat System.Net.HttpWebRequest.GetResponse()\r\nat System.Web.Services.Protocols.WebClientProtocol.GetWebResponse()\r\nat System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse()\r\nat System.Web.Services.Protocols.SoapHttpClientProtocol.doInvoke()\r\nat System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke()\r\nat InventCount_PDA_Part.InvDownUp.InvtService.GetInvt()\r\nat InventCount.FrmPartsList.menuItem4_Click()\r\nat System.Windows.Forms.MenuItem.OnClick()\r\nat System.Windows.Forms.Menu.ProcessMnuProc()\r\nat System.Windows.Forms.Form.WnProc()\r\nat System.Windows.Forms.Control._InternalWnProc()\r\nat Microsoft.AGL.Forms.EVL.EnterMainLoop()\r\nat System.Windows.Forms.Application.Run()\r\nat InventCount.FrmHome.Main()\r\n" "at System.Net.HttpWebRequest.finishGetResponse()\r\nat System.Net.HttpWebRequest.GetResponse()\r\nat System.Web.Services.Protocols.WebClientProtocol.GetWebResponse()\r\nat System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse()\r\nat System.Web.Services.Protocols.SoapHttpClientProtocol.doInvoke()\r\nat System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke()\r\nat InventCount_PDA_Part.InvDownUp.InvtService.GetInvt()\r\nat InventCount.FrmPartsList.menuItem4_Click()\r\nat System.Windows.Forms.MenuItem.OnClick()\r\nat System.Windows.Forms.Menu.ProcessMnuProc()\r\nat System.Windows.Forms.Form.WnProc()\r\nat System.Windows.Forms.Control._InternalWnProc()\r\nat Microsoft.AGL.Forms.EVL.EnterMainLoop()\r\nat System.Windows.Forms.Application.Run()\r\nat InventCount.FrmHome.Main()\r\n" string

Thank you,

GSReddy





Re: Device Emulator General Windows CE 5.0 MS Visual Studio 5.0 (WebRequest)

Apollo Strong

I went into emulator settings and chose the "right" network..."My Work" I think...and then it worked...





Re: Device Emulator General Windows CE 5.0 MS Visual Studio 5.0 (WebRequest)

C Dickson

Thanks every body. I got the solution. Connecting to the webservices through window immulstor need some step additional steps.

No additional hardware needed. You can install Microsoftloop back adapter.and assign a IP address.

In you webreference instead of localhost specify you configured IP address (e.i 192.0.0.1).

You have install Active sync 4.1 or latest version.

once runing you application or to open the emulator go to tools - device emulator select the emulator (e.i windows mobile smartphone emulator) connect then select cradle.

You have to configure the emulator proxy settings aswel