Question:
How do I update the area field for a shapefile (i.e. after projecting the dataset
or if there is no Shape_Area field to start with)?
Note: You can
find the solution/method by searching in the ArcGIS Desktop Help. Go to the
Index, search for the term "area", select the item "calculating
for polygons, then select "Updating area for a shapefile".
Here is a slightly
edited version of what is contained on that page:
- Optionally,
start an edit session in ArcMap. Calculating a field is faster outside of
an edit session, but you won't be able to undo the calculation.
- Open the attribute
table of the layer you want to edit.
- Right-click
the field heading for area (if there is no field for area values, you can
add a new field for area by clicking the Options button and selecting the
"Add field..." - make sure you specify the field type as 'float'
or 'double').
- Click Calculate
Values.
- Check the
Advanced box.
- Type the following
VBA statement in the first text box:
Dim dblArea as double
Dim pArea as IArea
Set pArea = [shape]
dblArea = pArea.area
- Type the
variable dblArea in the text box directly under the area field name.
Click OK.
The field in
your attribute table should now be filled in with the correct area values.