I am currently trying to write a script that iterates through files in a folder to do geoprocessing. However, I am getting held up at the very start of my code with an error I cannot explain or find an answer to. I am basically a novice at Python scripting, however, I have used arcpy and pyscripter successfully throughout my schooling to run moderately complex scripts and have never seen this error before.
This is the error I am getting:
ERROR: File "c:\program files (x86)\arcgis\desktop10.7\ArcToolbox\Toolboxes\kml_to_shp.py", line 20, in <module>
kmlFile = sys.argv # kml file
<type 'exceptions.IndexError'>: list index out of range
This is my script:
I should also mention that when I try to set arcpy.env.workspace it seems to be failing after I type in the "arcpy.env." "workspace" does not show up in the autocomplete list so I truly have no idea whats going on.