AnsweredAssumed Answered

is it possible to convert this AML into python? (arcedit)

Question asked by Fredou on Sep 14, 2016
Latest reply on Sep 15, 2016 by rastrauch

I'm trying to replicate this code (both delete) in python, my previous question is related to this

 

arcpy 10.3.1 being used with proper license

 

using coverage files

 

display 0
arcedit
&if [show program] ne ARCEDIT &then &do /*IF1
   &type ERROR: The Arcedit module could not be invoked
   &setvar run_status := -1002
   &return
&end /*IF1


/*** Remove non-topological lines
/*
graphics off
edit %path_poly_cover%

editfeature line
select line_type in {%valid_line_type_list%}
nselect
&if [show number select] gt 0 &then &do /*IF1
   delete
&end /*IF1


/*** Remove non-topological points
/*
editfeature point
select pnt_type in {%valid_pnt_type_list%}
nselect
&if [show number select] gt 0 &then &do /*IF1
   delete
&end /*IF1


save
removeedit %path_poly_cover% yes


/*** Return to the arc module
/*
&if [show program] eq ARCEDIT &then &do /*IF1
   removeedit all yes
   quit yes
&end /*IF1

Outcomes