Skip to main content
Home Forums Silverlight Programming Report a Silverlight Bug The remote server returned an unexpected response:(404)Not Found.
12 replies. Latest Post by drbarton on November 6, 2008.
(0)
Shaji-mji
Participant
1129 points
260 Posts
08-18-2008 8:47 AM |
I often get this error when Iam working on a silverlight app in visual studio 2008. Once I restart Vistal studio, it works fine.. Is this a bug? What should I do to get rid of this bug?
Iam using a wcf service that is in the same web so there is no issue of the service is running
HarshBar...
Star
9908 points
1,719 Posts
08-18-2008 8:53 AM |
Are you accessing some services.Because i was also facing same problem when i was working with wcf services.
It was due to the fact that some times those services were not running and some times it was taking wrong port for them.
Thanks,
tranduybien
Member
186 points
53 Posts
08-19-2008 12:48 PM |
Normaly I'm create new project for webservice then call it like http://localhost/mywebservice/service1.svc .......... After that I'm trying to create references with this webservice. Hope can fix your problem !
sankarcse
8 points
25 Posts
09-24-2008 2:40 AM |
I am aslo getting this same problem. How can i solve this issue??? :-)
11-05-2008 7:06 AM |
Try to check available of 2 files clientaccesspolicy.xml and crossdomain.xml and point detail binding method and accesspoint when you trying to call web-service:
BasicHttpBinding httpBinding = new BasicHttpBinding(BasicHttpSecurityMode.None); EndpointAddress endpoint = new EndpointAddress(InfoMap2D.Common.SysConfig.GetInstance().ServiceMap); httpBinding.MaxReceivedMessageSize = 200000; myService1 = new Service1SoapClient(httpBinding, endpoint);
CopyPast...
6 points
3 Posts
11-05-2008 10:07 AM |
I am running into the same problem.
My app starts to run and then dies with this error:
System.ServiceModel.CommunicationException was unhandled by user code Message="The remote server returned an error: NotFound" StackTrace: at System.ServiceModel.AsyncResult.End[TAsyncResult](IAsyncResult result) at System.ServiceModel.Channels.ServiceChannel.SendAsyncResult.End(SendAsyncResult 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 WiBotSilver.ProxyCode.RMAServiceClient.RMAServiceClientChannel.EndGetManufacturers(IAsyncResult result) at WiBotSilver.ProxyCode.RMAServiceClient.WiBotSilver.ProxyCode.IRMAService.EndGetManufacturers(IAsyncResult result) at WiBotSilver.ProxyCode.RMAServiceClient.OnEndGetManufacturers(IAsyncResult result) at System.ServiceModel.ClientBase`1.OnAsyncCallCompleted(IAsyncResult result) InnerException: System.Net.WebException Message="The remote server returned an error: NotFound" StackTrace: at System.Net.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state) at System.Net.BrowserHttpWebRequest.EndGetResponse(IAsyncResult asyncResult) at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse(IAsyncResult result) InnerException: System.Net.WebException Message="The remote server returned an error: NotFound" StackTrace: at System.Net.BrowserHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult) at System.Net.BrowserHttpWebRequest.<>c__DisplayClass5.<EndGetResponse>b__4(Object sendState) at System.Net.AsyncHelper.<>c__DisplayClass2.<BeginOnUI>b__0(Object sendState) InnerException:
I have clientaccesspolicy.xml defined in the website root. I DO NOT have crossdomain.xml defined at all.
Any idea what's going on?
tbrummel
4 points
2 Posts
11-06-2008 2:12 AM |
Ditto. I just busted out Silverlight 2 and VS 2008 to see if I could update my current ASP.NET site to use a silverlight control for login.
I got all the code working fine locally - referencing the System.Web.ApplicationServices.AuthenticationService.
When I deployed it to the real web, the first thing I ran into was that the service reference in the Silverlight app has an invalid endpoint. So I modified the XML file to be the actual URL on the web.
After I call AuthenticaionClient.LoginAsynch, my LoginCompleted handler gets a Error back in the result: The remote server returned an error: 404 NotFound.
I threw a clientaccesspolicy file on the server just in case but it sure looks to me like that would only come into play cross-domain -- and all this is running on the same web server.
drbarton
10 points
14 Posts
11-06-2008 4:59 AM |
CopyPasteGhost: Message="The remote server returned an error: NotFound" StackTrace: at System.ServiceModel.AsyncResult.End[TAsyncResult](IAsyncResult result) at System.ServiceModel.Channels.ServiceChannel.SendAsyncResult.End(SendAsyncResult 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 WiBotSilver.ProxyCode.RMAServiceClient.RMAServiceClientChannel.EndGetManufacturers(IAsyncResult result) at WiBotSilver.ProxyCode.RMAServiceClient.WiBotSilver.ProxyCode.IRMAService.EndGetManufacturers(IAsyncResult result) at WiBotSilver.ProxyCode.RMAServiceClient.OnEndGetManufacturers(IAsyncResult result) at System.ServiceModel.ClientBase`1.OnAsyncCallCompleted(IAsyncResult result) InnerException: System.Net.WebException Message="The remote server returned an error: NotFound" StackTrace: at System.Net.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state) at System.Net.BrowserHttpWebRequest.EndGetResponse(IAsyncResult asyncResult) at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse(IAsyncResult result) InnerException: System.Net.WebException Message="The remote server returned an error: NotFound" StackTrace: at System.Net.BrowserHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult) at System.Net.BrowserHttpWebRequest.<>c__DisplayClass5.<EndGetResponse>b__4(Object sendState) at System.Net.AsyncHelper.<>c__DisplayClass2.<BeginOnUI>b__0(Object sendState) InnerException: I have clientaccesspolicy.xml defined in the website root. I DO NOT have crossdomain.xml defined at all.
Message="The remote server returned an error: NotFound" StackTrace: at System.ServiceModel.AsyncResult.End[TAsyncResult](IAsyncResult result) at System.ServiceModel.Channels.ServiceChannel.SendAsyncResult.End(SendAsyncResult 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 WiBotSilver.ProxyCode.RMAServiceClient.RMAServiceClientChannel.EndGetManufacturers(IAsyncResult result) at WiBotSilver.ProxyCode.RMAServiceClient.WiBotSilver.ProxyCode.IRMAService.EndGetManufacturers(IAsyncResult result) at WiBotSilver.ProxyCode.RMAServiceClient.OnEndGetManufacturers(IAsyncResult result) at System.ServiceModel.ClientBase`1.OnAsyncCallCompleted(IAsyncResult result) InnerException: System.Net.WebException Message="The remote server returned an error: NotFound" StackTrace: at System.Net.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state) at System.Net.BrowserHttpWebRequest.EndGetResponse(IAsyncResult asyncResult) at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse(IAsyncResult result) InnerException: System.Net.WebException Message="The remote server returned an error: NotFound" StackTrace: at System.Net.BrowserHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult) at System.Net.BrowserHttpWebRequest.<>c__DisplayClass5.<EndGetResponse>b__4(Object sendState) at System.Net.AsyncHelper.<>c__DisplayClass2.<BeginOnUI>b__0(Object sendState) InnerException:
I have exactly the same problem. Any idea ?
11-06-2008 5:53 AM |
Try to put crossdomain.xml into your project
11-06-2008 9:03 AM |
What goes in the crossdomain.xml?
11-06-2008 9:16 AM |
1 2 <!DOCTYPE cross-domain-policy 3 SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd"> 4 <cross-domain-policy> 5 <allow-access-from domain="*" /> 6 </cross-domain-policy>
11-06-2008 9:20 AM |
And this goes in the web root at the same place as the "ClientAccessPolicy.xml"?
11-06-2008 9:40 AM |
Exactly