I have a script that I use to convert text files into LAS files- there are 400 files. How would I make a batch script or loop to tell Python to keep grabbing the next file and keep converting until it reaches the end of the folder?
You can loop through a folder to get all your text files.
for root, dirs, files in os.walk(folder):
for filename in files:
input_file = os.path.join(root, filename)
# You can then run your conversion script here
# Use input_file for your input into your script.
I would look into using arcpy.da.walk.
Or, since this isn't ESRI data specific, you can use regular old os.walk.
You could try something like the following:
for filename in os.listdir('dirname'):
# code to convert file here
Retrieving data ...