I created a new empty feature class and then appended features into it from another feature. When I zoomed to that new feature class, it zoomed way out as if the extent was whacked; and it was. So I used the recalculate feature class extent tool and it was still whacky. Then I recalculated the the spatial index and it zooms correctly.
However, when I look at the feature class properties I see these Max/Mins:
But when I use arcpy.Describe I get slightly different values:
fc = r'N:\GIS\AddressDataManagement\FixSLCoMistakes\FixSLCoMistakes.gdb\SubdivsionsMagna'
desc = arcpy.Describe(fc)
xmin = desc.extent.XMin
xmax = desc.extent.XMax
ymin = desc.extent.YMin
ymax = desc.extent.YMax
print(f'Xmin = {xmin} Xmax = {xmax} Ymin = {ymin} Ymax = {ymin}')
Xmin = 1471194.3071583062 Xmax = 1484253.9831386397 Ymin = 7418358.292630732 Ymax = 7418358.292630732
Two questions:
1. Why did I need to recalc the spatial index to get my extents to behave?
2. Why do I see different values between the properties pane and arcpy.Describe?
Solved! Go to Solution.
coordinates were in meters, hence the feet-meters difference
you have to recalculate the spatial index because the empty featureclass probably didn't have and extent or it had one in a different coordinate system.
First issue can be fixed by working only in meters 😉 or wait 16 days
coordinates were in meters, hence the feet-meters difference
you have to recalculate the spatial index because the empty featureclass probably didn't have and extent or it had one in a different coordinate system.
First issue can be fixed by working only in meters 😉 or wait 16 days
I'm going with the 16 days. I have my own version of an Advent Calendar on my desk.