Select to view content in your preferred language

My Rest Service kills my Silverlight App

766
3
03-27-2012 08:50 AM
RyanStowasser
New Contributor
This is my first ArcGIS application. I was given a REST service to connect to for display purposes, but every different way I try to connect to it kills my app. The app displays white, and I can not see the ESRI watermark or the colored background of the app.

if you go to the REST service Url, I can use the links to display the Layer throught Javascript and through the ArcGIS.com Map. The information looks correct there, but when I put the same url in my silverlight app, it doesn't work.

What am I doing wrong?

Link to the service: removed

 <esri:Map Background="Blue" HorizontalAlignment="Left" Name="map1"  VerticalAlignment="Top" WrapAround="True" Height="600" Width="800">
            <esri:Map.Layers>
                <esri:LayerCollection>
                    <!-- works -->
                    <!-- <esri:ArcGISTiledMapServiceLayer 
                        ID="BaseLayer" 
                        Url="http://services.arcgisonline.com/ArcGIS/rest/services/ESRI_StreetMap_World_2D/MapServer" />-->
                    <esri:ArcGISTiledMapServiceLayer 
                        ID="BaseLayer" 
                        Url="http://[removed]/ArcGIS/rest/services/taxlots/MapServer" />
                    
                </esri:LayerCollection>
            </esri:Map.Layers>
        </esri:Map>


this is the map I want to create for my silverlight application: http://www.arcgis.com/home/webmap/viewer.html?url=http%3a%2f%2fgis.ashland.or.us%2fArcGIS%2frest%2fs...
0 Kudos
3 Replies
JenniferNery
Esri Regular Contributor
This blog post might be helpful: http://blogs.esri.com/esri/arcgis/2009/08/24/troubleshooting-blank-layers/. You can update the client access policy with this: http://server.arcgisonline.com/clientaccesspolicy.xml. Your service currently only allow SOAPAction. This is causing Silverlight security exception.
0 Kudos
RyanStowasser
New Contributor
Thank you jenniferdnery for the links.

I was able to update my clientaccesspolicy.xml, but I was still getting the blank screen. It ended up that I needed to use an ArcGISDynamicMapServiceLayer object instead of the ArcGISTiledMapServiceLayer object.
0 Kudos
JenniferNery
Esri Regular Contributor
Yes. I believe your service was SingleFusedMapCache=False.
0 Kudos