If it is surface bodies that you want to measure your area, this code could serve you, you must identify by item to which body you want to measure. I hope the code is useful, regards
Dim oDoc As Document = ThisDoc.Document
Dim dArea As Double
Dim Ident As Integer = 1 '''Identify WorkSurface
Dim oSurf As SurfaceBodies
oSurf = oDoc.ComponentDefinition.WorkSurfaces.Item(1).SurfaceBodies
For Each oSurfBody As SurfaceBody In oSurf
For Each oFace As Face In oSurfBody.Faces
dArea = Round(oFace.Evaluator.Area/1000000,3)
iProperties.Value("Custom", "Surface_Area_PA")=dArea & " m^2"
Next
Next
Please accept as solution and give likes if applicable.
I am attaching my Upwork profile for specific queries.
Sergio Daniel Suarez
Mechanical Designer
| Upwork Profile | LinkedIn