private function setFloorLayerDef(floor:String) : void { for (var i:int = 0; i < opLayers.length; i++){ trace(opLayers.label); if (opLayers.label == "Category Codes" || opLayers.label == "Organizations") { trace("set Floor " + opLayers.label); opLayers.layerDefinitions = [null, null, null, null, "Floor = '" + floor + "'", "Floor = '" + floor + "'", null, null, null, null, null, null, null, null,]; trace(opLayers.layerDefinitions); //identifyParams.layerIds = i; //ViewerContainer.getInstance().mapManager.map.getLayer(opLayers.label).visible = true; } } }
Solved! Go to Solution.
private function setFloorLayerDef(floor:String) : void { for (var i:int = 0; i < opLayers.length; i++){ trace(opLayers.label); if (opLayers.label == "Category Codes" || opLayers.label == "Organizations") { trace("set Floor " + opLayers.label); var layer:Layer = opLayers.layer; if (layer is ArcGISDynamicMapServiceLayer) { ArcGISDynamicMapServiceLayer(layer).layerDefinitions = [null, null, null, null, "Floor = '" + floor + "'", "Floor = '" + floor + "'", null, null, null, null, null, null, null, null,]; } trace(opLayers.layerDefinitions); //identifyParams.layerIds = i; //ViewerContainer.getInstance().mapManager.map.getLayer(opLayers.label).visible = true; } } }
private function setFloorLayerDef(floor:String) : void { for (var i:int = 0; i < opLayers.length; i++){ trace(opLayers.label); if (opLayers.label == "Category Codes" || opLayers.label == "Organizations") { trace("set Floor " + opLayers.label); var layer:Layer = opLayers.layer; if (layer is ArcGISDynamicMapServiceLayer) { ArcGISDynamicMapServiceLayer(layer).layerDefinitions = [null, null, null, null, "Floor = '" + floor + "'", "Floor = '" + floor + "'", null, null, null, null, null, null, null, null,]; } trace(opLayers.layerDefinitions); //identifyParams.layerIds = i; //ViewerContainer.getInstance().mapManager.map.getLayer(opLayers.label).visible = true; } } }
import com.esri.ags.layers.DynamicMapServiceLayer; import com.esri.ags.layers;
import com.esri.ags.layers.ArcGISDynamicMapServiceLayer;