Select to view content in your preferred language

Legend display in Map

2910
3
Jump to solution
06-08-2014 08:02 PM
RamanaSonthi
New Contributor
I created data driven pages in Arc 10.1. For the DDP, using the new legend functionality of 10.1 for displaying only visible features in the different extents for different maps. Some of the maps have no features of the layers in the legend. How come the legend will automatically turn off for some maps where there is no visible features.
Regards
Ram
0 Kudos
1 Solution

Accepted Solutions
JeffBarrette
Esri Regular Contributor
Thank you for the clarification.  I understand your issue.

This can not be done using DDP alone.  You could accomplish this using Python scripting.  Via arcpy.mapping you can count the number of items in the legend.  If the item count = 0, then move the legend off the page.

http://resources.arcgis.com/en/help/main/10.2/#/LegendElement/00s300000041000000/

Jeff

View solution in original post

0 Kudos
3 Replies
JeffBarrette
Esri Regular Contributor
I'm not sure I understand your question.  I sounds to me like the legend is doing what you need it to do.

Jeff
0 Kudos
RamanaSonthi
New Contributor
I'm not sure I understand your question.  I sounds to me like the legend is doing what you need it to do.

Jeff


Hi Jeff,

I am giving more detail about my question. I have multiple maps created with DDP with multiple legends. All the legends showing different layers. Most of the map legends show classes that are visible in the current map indexes. Only few maps and some legends don't have any classes in the visible map extent. At that time only the blank legend frame is showing on the maps. Is there any way that we can't show the legend frame if there are any classes not visible in the current extent.

Ram
0 Kudos
JeffBarrette
Esri Regular Contributor
Thank you for the clarification.  I understand your issue.

This can not be done using DDP alone.  You could accomplish this using Python scripting.  Via arcpy.mapping you can count the number of items in the legend.  If the item count = 0, then move the legend off the page.

http://resources.arcgis.com/en/help/main/10.2/#/LegendElement/00s300000041000000/

Jeff
0 Kudos