Select to view content in your preferred language

SPATIAL REFERENCE

987
2
06-17-2010 12:47 PM
JuneAcosta
Frequent Contributor
I have searched the forum for this information but I couldn't find the answer.

I am not real clear on handling the spatial reference. I'm using ESRI's online World Street Map Service with my tiled service. The street layer shows up in the map, but not my tiled service. I'm modifying an existing sample- in this sample the spatial reference is set to wkid 102100. Do I need to set this same spatial reference (WGS_1984_Web_Mercator_Auxiliary_Sphere) in the MXD that that I use for my tiled service?
0 Kudos
2 Replies
NeelMallepally
Emerging Contributor
I have searched the forum for this information but I couldn't find the answer.

I am not real clear on handling the spatial reference. I'm using ESRI's online World Street Map Service with my tiled service. The street layer shows up in the map, but not my tiled service. I'm modifying an existing sample- in this sample the spatial reference is set to wkid 102100. Do I need to set this same spatial reference (WGS_1984_Web_Mercator_Auxiliary_Sphere) in the MXD that that I use for my tiled service?


Is the Spatial reference of your Tiled Map Service same as the ESRI's online world street map (or which ever you are using)?

You can't add two Tiled map service layers having different spatial reference to a map object. Since the cache has generated tiles of the layers with their corresponding spatial reference, the tiles will not align when you try to add two Tiled map service layers to a map object. You can declare your Tiled map service as DynamicMapService in your code.

In the below code, windspeed service is actually a Tiled service.
var basemap = new esri.layers.ArcGISTiledMapServiceLayer("http://server.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer");
        map.addLayer(basemap);

 var windspeed = new esri.layers.ArcGISDynamicMapServiceLayer("http://maps.lsuagcenter.com/ArcGIS/rest/services/LAWinds/LABWS/MapServer"); 
 map.addLayer(windspeed);
0 Kudos