Select to view content in your preferred language

Displaying attribute count in ArcMap

2312
4
11-09-2011 11:47 AM
by Anonymous User
Not applicable
Original User: exoscoriae

There is an old archived topic with this title in which the author is looking to show the number of unique occurrences in the legend for a given attribute. 

ie:
wells - 92
people - 32
cows - 2

A commonly used macro was given as the response located here:
http://edndoc.esri.com/arcobjects/9.2/CPP_VB6_VBA_VCPP_Doc/COM_Samples_Docs/Cartography/Renderers/aa...

The macro had issues in that it had to be re-run each time, and then the legend had to be cut & pasted to force a refresh.

Now the macro seems to have a bigger issue in that Visual basic is no longer supported (as I understand it).

I am on 10sp2 looking for a way to address this same issue.  Any suggestions in light of the demise of VB would be very appreciated.  With the amount of VB resources that had been developed previously, it makes it very difficult to find non-VB solutions to these simple problems.

thanks,
0 Kudos
4 Replies
by Anonymous User
Not applicable
Original User: jbarrette

I'm not familiar with the script you are referring to but are you trying to get a feature count for the number of features in the visible extent?  FYI - this has been added as a legend property at 10.1.

Jeff
0 Kudos
by Anonymous User
Not applicable
Original User: exoscoriae

excellent - is there a helpfile or resource online describing this process?  Nothing came up in my search.
0 Kudos
JeffBarrette
Esri Regular Contributor
The only way you will be able to see the help for 10.1 is if you have access to beta.  Attached is a screenshot showing the new legend paramater.

Jeff
0 Kudos
by Anonymous User
Not applicable
Original User: exoscoriae

Ah, I see now.  I was getting 10.1 confused with 10svp1.  Thanks!
0 Kudos