Thanks Robert for pointing me in this direction! I got to a point in the .as code where I can stop a sublayer from displaying completely. However, I still want the data to display if the root layer is activated. This is the code I am working with at the moment: if (layerInfos)
{
var rootLayers:Array = findRootLayers(layerInfos);
for each (var layerInfo:LayerInfo in rootLayers)
{
var name:String = layerInfo.name;
if (name=='Transportation Projects')
{
// addChild(createTocLayer(this, layerInfo, layerInfos, visibleLayers, layer));
}
else
{
addChild(createTocLayer(this, layerInfo, layerInfos, visibleLayers, layer));
}
}
}With the code as-is, the layer Transportation Projects (which is a group layer within a map service) will not display. I would assume if I can remove the right arguements from the 'addChild' code, I can make the layer continue to display, without allowing the user to drill into the sublayers. When I attempt to change the 'addChild' code, I get a variety of errors, since I am messing with properties. Any ideas to work around this? Thank you for your help!Colter