monzay

zoom to graphic from drop down list that is populated with queryTask

Discussion created by monzay on Nov 23, 2011
Latest reply on Nov 23, 2011 by monzay
I want to zoom to a feature (graphic) when a user selects it from a dojo filtering select list. This list is populated using a queryTask. Is it okay to execute a second queryTask that takes the same results and does something else with it?

 
function HAPCexecuteQueryTask(fmc) {
         HAPCquery.where = "FisheryManagementCouncil = '"+ fmc +"'";
  HAPCqueryTask.execute(HAPCquery,populateList);
  HAPCqueryTask.execute(HAPCquery,showResults);
  }


I have been looking at this example and it seems to be pretty close to what I want to do (see last entry for solution.
http://forums.arcgis.com/threads/36317-Zoom-to-Graphic?highlight=graphics

Outcomes