@@ -218,7 +218,7 @@ def locateEventTable(
218218
219219 if not desc .hasZ :
220220 addMsgAndPrint (" adding Z values" )
221- arcpy .AddSurfaceInformation_3d (pts , dem , zType , "LINEAR" )
221+ arcpy .da . AddSurfaceInformation (pts , dem , zType , "LINEAR" )
222222
223223 ## working around bug in LocateFeaturesAlongRoutes
224224 # add special field for duplicate detection
@@ -303,9 +303,9 @@ def locateEventTable(
303303arcpy .env .overwriteOutput = True
304304
305305try :
306- arcpy .CheckOutExtension ("3D " )
306+ arcpy .CheckOutExtension ("Spatial " )
307307except :
308- addMsgAndPrint ("\n Cannot check out 3D-analyst extension." )
308+ addMsgAndPrint ("\n Cannot check out Spatial Analyst extension." )
309309 sys .exit ()
310310
311311## Checking section line
@@ -367,7 +367,7 @@ def locateEventTable(
367367 # Add Z values
368368 addMsgAndPrint (" getting elevation values for " + shortName (tempXsLine ))
369369 Zline = arcpy .CreateScratchName ("xx" , outFdsTag + "_Z" , "FeatureClass" , scratch )
370- arcpy .InterpolateShape_3d (dem , tempXsLine , Zline )
370+ arcpy .da . InterpolateShape (dem , tempXsLine , Zline )
371371 # Add M values
372372 addMsgAndPrint (" measuring " + shortName (Zline ))
373373 ZMline = arcpy .CreateScratchName ("xx" , outFdsTag + "_ZM" , "FeatureClass" , scratch )
@@ -679,7 +679,7 @@ def locateEventTable(
679679 testAndDelete (f )
680680 del inRows , outRows
681681
682- arcpy .CheckInExtension ("3D " )
682+ arcpy .CheckInExtension ("Spatial " )
683683if not saveIntermediate :
684684 addMsgAndPrint ("\n Deleting intermediate data sets" )
685685 for fc in tempXsLine , ZMline , Zline , tempBuffer :
0 commit comments