Robert,I am a little confused how to how to use the same querytask. Where do you set the different url for the querytask? Do you by chance have a simple example or know where I could find one.Thank you again for all your help. Here is my code:private function doQuery():void
{
// clear the graphics layer
myGraphicsLayer.clear();
queryTask.execute(query, new AsyncResponder(onResult, onFault));
function onResult(featureSet:FeatureSet, token:Object = null):void
{
if (featureSet.features.length == 0)
{
Alert.show("No Parcel Found.");
}
else
{
var graphicsExtent:Extent = GraphicUtil.getGraphicsExtent(featureSet.features);
if (graphicsExtent)
{
map.extent = graphicsExtent;
}
}
}
function onFault(info:Object, token:Object = null):void
{
Alert.show(info.toString());
}
}
<esri:QueryTask id="queryTask"
url="http://gis2.stallingsnc.org:8084/Stallings/rest/services/Flex2/ParcelsAgain/MapServer/0"
useAMF="false"/>
<esri:Query id="query"
where="ACCTNO like '%{fText.text}%'"
outSpatialReference="{map.spatialReference}"
returnGeometry="true"
text="{fText.text}">
<esri:outFields>
<fx:String>ACCTNO</fx:String>
<fx:String>Owner1</fx:String>
</esri:outFields>
</esri:Query>