Click here to Skip to main content
15,851,915 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
Hi all. After faithfully following an article called "How to connect to a local web service from the Windows Phone 8 emulator" right here:

http://msdn.microsoft.com/en-us/library/windowsphone/develop/jj684580%28v=vs.105%29.aspx[^],

and running the application. After a short while,

I can see the application is installed on the phone, pauses for a noticeable amount of time (maybe), the throws the exception:

C#
System.TimeoutException was unhandled by user code
  HResult=-2146233083
  Message=The remote server returned an error: NotFound.
  Source=System.ServiceModel
  StackTrace:
       at System.ServiceModel.AsyncResult.End[TAsyncResult](IAsyncResult result)
       at System.ServiceModel.Channels.ServiceChannel.EndCall(String action, Object[] outs, IAsyncResult result)
       at System.ServiceModel.ClientBase`1.ChannelBase`1.EndInvoke(String methodName, Object[] args, IAsyncResult 

result)
       at PhoneApp1.ServiceReference1.Service1Client.Service1ClientChannel.EndGetData(IAsyncResult result)
       at PhoneApp1.ServiceReference1.Service1Client.PhoneApp1.ServiceReference1.IService1.EndGetData(IAsyncResult 

result)
       at PhoneApp1.ServiceReference1.Service1Client.OnEndGetData(IAsyncResult result)
       at System.ServiceModel.ClientBase`1.OnAsyncCallCompleted(IAsyncResult result)
  InnerException: System.Net.WebException
       HResult=-2146233079
       Message=The remote server returned an error: NotFound.
       Source=System.Windows
       StackTrace:
            at System.Net.Browser.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state)
            at System.Net.Browser.ClientHttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
            at 

System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse

(IAsyncResult result)
       InnerException: System.Net.WebException
            HResult=-2146233079
            Message=The remote server returned an error: NotFound.
            Source=System.Windows
            StackTrace:
                 at System.Net.Browser.ClientHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult)
                 at System.Net.Browser.ClientHttpWebRequest.<>c__DisplayClasse.<EndGetResponse>b__d(Object 

sendState)
                 at System.Net.Browser.AsyncHelper.<>c__DisplayClass1.<BeginOnUI>b__0(Object sendState)
            InnerException: 


I have been at this problem for weeks now and nothing seems to fix this solution. I have tried when the Windows Firewall is Off, When the Anti-Virus is not running. I am using an actual device for testing as my computer cannot run an emulator due to lack of HW Virtualization. It is running on Windows 8.0 64bit, and i am using Visual Studio 2013. Please assist me solve this problem for it is driving me crazy.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900