ArcGIS Server » Web Applications » Flex API
 
 

Code Gallery

Asynchronous GP Tool

This sample demonstrates how to run an Asynchronous GP tool, handle its results and display them on the map.
Author saur5784
Date Submitted 12-23-2008
Date Last Updated 12-23-2008
Language Flex
Product/Version ArcGIS Server 9.3
Views 2129
Downloads 583
License Type ESRI Attribution and License Agreement
(2 ratings)

Report Inappropriate Content: This Code Gallery is intended for the free exchange of code related to ESRI software products. Let us know if this entry is inappropriate (e.g., a download for a commercial product).

 

zoom to each segment of resultant route   posted by saya on Feb 09, 2009 12:08 AM

i was trying out the code. great sample. do you have any idea how the sample can be tweaked to allow the user to click and zoom to each section of the resultant directions, like that provided by the desktop arcgisnavigator Directions?

RE : zoom to each segment of resultant route   posted by saur5784 on Feb 12, 2009 1:49 PM

this can be done in many ways, here is one... import com.esri.ags.geometry.Polyline; private function onClick(event:MouseEvent):void { const graphic:Graphic = Graphic(event.target); var extent:Extent = Polyline(graphic.geometry).extent; mymap.extent = extent; }

RE : zoom to each segment of resultant route   posted by saur5784 on Feb 12, 2009 1:52 PM

And have onClick in the graphics layer =>