I believe the syntax for this property is incorrect.Should be a single array like...["LAND_NAME", "LAND_CODE"]Hope that helps.
query.outFields = ["LAND_NAME"],["LAND_CODE"];
<mx:DataGridColumn id="dgc" dataField="PARCELID"/>
dgc.dataField = 'LAND_NAME';
<mx:DataGrid dataProvider="{queryTask.executeLastResult.attribu tes}" scroll="true" width="100%" height="40%"/>
<mx:DataGrid dataProvider="{queryTask.executeLastResult.attributes}" scroll="true" width="100%" height="40%"> <mx:columns> <mx:DataGridColumn dataField="PARCELID"/> </mx:columns> </mx:DataGrid>
private function doQuery():void { if (myLAYER.selectedItem.data == 2) { query.outFields = ['ZONING_CODE']; } else if (myLAYER.selectedItem.data == 1) { query.outFields = ['LANDUSE_CODE']; } queryTask.execute(query, new AsyncResponder(onResult, onFault)); }
Membros conectados podem postar, seguir atualizações e mais. Novo aqui? Registre uma conta gratuita.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.