AnsweredAssumed Answered

Listing layers in a group

Question asked by agehlot on Jun 21, 2016
Latest reply on Feb 27, 2018 by oliver_burdgis



I am trying to use arcpy to list all of the layers in a group to apply symbology to all of them at once. When I use the arcpy.mapping.ListLayers(mxd, "Group Layer", df), it only returns the name of the group layer and not the layers within the group, so I am unable to iterate through them. I've tried several different queries, but all I seem to get it to do is list every single layer in the document (not what I want) or just the group layer name (also not what I want).


Does anyone know how to specify it to list all of the layers in the group? The ArcGIS help tells me it should be able to do that, listing first the name of the group layer followed by each layer within the group, but it is not working for me.