Hello,Is there a way to read the extent from a map and set it (in lat/lon with projection?)For example:<esri:Map id="myMap" width="100%" height="100%" mapClick="mapClickHandler(event)" timeSlider="{myFirstTimeSlider}" openHandCursorVisible="false" wrapAround180="true"> <esri:Extent id="initExent" xmin="-10854962" ymin="4514317" xmax="-10779136" ymax="4572944"> <esri:SpatialReference wkid="102100"/> </esri:extent> <esri:ArcGISDynamicMapServiceLayer id="myDynamicService" fault="myDynamicService_faultHandler(event)" load="myTimeLayer_loadHandler(event)" loadError="myDynamicService_loadErrorHandler(event)"/> <esri:GraphicsLayer id="clickGraphicsLayer"/> </esri:Map>
Here, instead of the below codes, that specifies the value for the extent (some number): <esri:Extent id="initExent" xmin="-10854962" ymin="4514317" xmax="-10779136" ymax="4572944"> <esri:SpatialReference wkid="102100"/> </esri:extent>
Can I read from the map that I'm loading? Maybe like: myDynamicService.initialExtent.xmin, myDynamicService.initialExtent.xmax, etc...?? The extent for my map is set in lat/lon values, and so the projection also needs to be set. I don't know how to do this, because when I tried, at this time the values are 0.<esri:Extent id="initExent" xmin="{myDynamicService.initialExtent.xmin}" ymin="{myDynamicService.initialExtent.ymin}" xmax="{myDynamicService.initialExtent.xmax}" ymax="{myDynamicService.initialExtent.}"> <esri:SpatialReference wkid="{myDynamicService.spatialReference}"/> </esri:extent>
Please help! thank you!!