Select to view content in your preferred language

Can the projection of the Map control can be changed dynamically in the code behind?

497
2
08-31-2010 10:35 AM
weiliang
Deactivated User
Hi,

To use ESRI provided map service (WGS 84), all our map services are been projected onto the WGS84 coordinate system and added into the map control during initialization phase. However, to generate a relatively accurate length (e.g., 500 feet) segment on our map, I want to change the map projection into State Plane. Is there any way that I can do this?

Thanks in advance!

Wei
0 Kudos
2 Replies
dotMorten_esri
Esri Notable Contributor
You can only change the map's projection when the map's Layers collection is empty or before the map loads.
Setting the spatial reference of the map is done simply by setting a startup extent, and ensuring that the spatial reference of that extent is defined.
0 Kudos
weiliang
Deactivated User
Many thanks, Morten. Have a great afternoon!

Wei
0 Kudos