Select to view content in your preferred language

Error

786
1
05-08-2012 10:43 AM
RickWarner
Occasional Contributor
I just finished a tutorial on creating my first application in silverlight using arconline services. I then tried to create the application in a new website and it stopped generating the following error. Why did I get this error?
If the cross domain worked for the tutorial, why not when applied to a new website?  Both are made on same developer machine, using aspnet development server.

  "Unhandled Error in Silverlight Application A security exception occured while trying to connect to the REST endpoint. Make sure you have a cross domain policy file available at the root for your server that allows for requests from this application.   at ESRI.ArcGIS.Client.Layer.OnInitializationFailed(EventArgs e)
   at ESRI.ArcGIS.Client.Layer.Initialize()
   at ESRI.ArcGIS.Client.ArcGISTiledMapServiceLayer.<>c__DisplayClass1a.<MapServiceInfoInitFailed>b__18()  eval code, line 1 character 1"

How do you add the cross domain policy file to the root to a deveoper server?
Thanks for any help.
0 Kudos
1 Reply
ShreyasVakil
Frequent Contributor
If you are using online services, then it should not ask you to add crossdomain.xml, because it is already there. You can check at http://services.arcgisonline.com/crossdomain.xml . Can you post some code or maybe the URL of the services you are accessing.
0 Kudos