request error
-
I see the following error while connecting to a wcf service through my silverlight application. An error occurred while trying to make a request to URI 'http://localhost:3046/Service1.svc'. This could be due to attempting to access a service in a cross-domain way without a proper cross-domain policy in place, or a policy that is unsuitable for SOAP services. You may need to contact the owner of the service to publish a cross-domain policy file and to ensure it allows SOAP-related HTTP headers to be sent. This error may also be caused by using internal types in the web service proxy without using the InternalsVisibleToAttribute attribute. Please see the inner exception for more details.
Tauseef A Khan MCP Dotnet framework 2.0.
-
I see the following error while connecting to a wcf service through my silverlight application. An error occurred while trying to make a request to URI 'http://localhost:3046/Service1.svc'. This could be due to attempting to access a service in a cross-domain way without a proper cross-domain policy in place, or a policy that is unsuitable for SOAP services. You may need to contact the owner of the service to publish a cross-domain policy file and to ensure it allows SOAP-related HTTP headers to be sent. This error may also be caused by using internal types in the web service proxy without using the InternalsVisibleToAttribute attribute. Please see the inner exception for more details.
Tauseef A Khan MCP Dotnet framework 2.0.
How are you hosting the WCF app? How are you hosting the Silverlight app? If the Silverlight app isn't hosted at http://localhost:3046 then you'l have a cross domain issue. That means you'll need to provide a clientaccesspolicy.xml file at the root of the domain the WCF service is hosted at. Making a Service Available Across Domain Boundaries[^] If you're hosting the WCF service in WcfSvchost.exe or self hosting, you may need to serve up the clientaccesspolicy.xml yourself: Enabling cross-domain calls for Silverlight apps on self-hosted web services[^] Or you can host your WCF service in IIS[^] and just put the clientaccesspolicy.xml at the root of the host domain.
Mark Salsbery Microsoft MVP - Visual C++ :java:
-
How are you hosting the WCF app? How are you hosting the Silverlight app? If the Silverlight app isn't hosted at http://localhost:3046 then you'l have a cross domain issue. That means you'll need to provide a clientaccesspolicy.xml file at the root of the domain the WCF service is hosted at. Making a Service Available Across Domain Boundaries[^] If you're hosting the WCF service in WcfSvchost.exe or self hosting, you may need to serve up the clientaccesspolicy.xml yourself: Enabling cross-domain calls for Silverlight apps on self-hosted web services[^] Or you can host your WCF service in IIS[^] and just put the clientaccesspolicy.xml at the root of the host domain.
Mark Salsbery Microsoft MVP - Visual C++ :java:
-
wcf service is in the solution where silverlight application is. i m hosting silverlight app in a web application in the same solution.
Tauseef A Khan MCP Dotnet framework 2.0.
Tauseef A wrote:
wcf service is in the solution where silverlight application is. i m hosting silverlight app in a web application in the same solution.
The project/solution has no relevance here. I mean the web hosts...WcfSvcHost...IIS....Self Hosting?
Mark Salsbery Microsoft MVP - Visual C++ :java:
-
Tauseef A wrote:
wcf service is in the solution where silverlight application is. i m hosting silverlight app in a web application in the same solution.
The project/solution has no relevance here. I mean the web hosts...WcfSvcHost...IIS....Self Hosting?
Mark Salsbery Microsoft MVP - Visual C++ :java:
-
Then you'll definitely want to study the information at the links I provided to understand the cross-domain issue and how to deal with it.
Mark Salsbery Microsoft MVP - Visual C++ :java:
-
Then you'll definitely want to study the information at the links I provided to understand the cross-domain issue and how to deal with it.
Mark Salsbery Microsoft MVP - Visual C++ :java:
-
The WcfSvcHost is for testing/debugging. You'll probably want to consider how it will work when the service is actually deployed. I find hosting on IIS the easiest and most flexible.
Mark Salsbery Microsoft MVP - Visual C++ :java: