# Doing Math calculations within ArcMap Dynamic Text?

Is it posssible to perform any math on ESRI ArcMap dynamic text? For example I have the area of a SDE park layer's SHAPE.AREA, but it is in m2 because the layer is in NAD_1983_UTM_Zone_17N. I want to show the area in hectares (m2 / 10000). How do I do this? Is it possible to add two fields together and display it in dynamic text?

• You can just create a field in the attribute table and use the field calculator. ESRI Help Files – Roy Oct 11 '12 at 14:44
• No, I want it done in the dynamic text. Adding fields in a SDE layer everytime I want to do some math is not a practicable option. The labeling allows math to be done, but I want it in dynamic text where it doesn't cover the features in the map. – David Oct 11 '12 at 15:00

This from Jeffrey Barrette, an ESRI employee:

No. Dynamic Text provides many different formatting options for dates, times, coord systems, etc but it does not provide the logic to perform mathematical operations. You would need to incorporate Python and then use arcpy.mapping to update text elements in a layout.

To do this you can edit the field properties (right click the field in the attribute table) and set the NUMBER FORMAT to RATE (halfway down on the right hand side) and then edit the rate (basically a divide by) and suffix e.g. hec.

There are further options for decimal places and justification if you want to further change the display.

These options will change how the number looks in labels and when being referenced by data driven pages.

You can use the Data Driven Page Display Expression option . So in your case the display expression on the Display tab of the Layer properties would be SHAPE.AREA/10000

http://desktop.arcgis.com/en/arcmap/10.3/map/page-layouts/using-dynamic-text-with-data-driven-pages.htm

Open layer Properties and go to the Labels tab. Click the Expression Button. Type your calculation (Area/10000 in this case) inside the expression area.

Make sure that Labeling is enabled for this layer.