I have a field that displays a list of files in a folder. I then open each file, check how many lines each file has, and put that information directly next to the file name in the field (e.g., "File 1, 123"). I am then using a repeat loop to examine each file, and if it does not have a certain number of lines, I want to move that file to a new folder.
Code: Select all
myFile = "C:/Users/PC/Desktop/REHalldata/Output_Session1_A10LVHTF26QHQC_a7ess6el98.csv"
goodFolder = "C:/Users/PC/Desktop/REHalldata/Good"
I've tried it a bunch of ways and it never works!
Code: Select all
rename URL("file:" & myFile) to specialFolderPath(goodFolder)
rename URL("file:" & myFile) to specialFolderPath(tFolder & "/" & "Good")
rename file myFile to specialFolderPath(tFolder & "/" & "Good")
rename file myFile to specialFolderPath("\Good")
rename file myFile to specialFolderPath("Good")