22 lines
594 B
AppleScript
22 lines
594 B
AppleScript
set baseDate to "20250102_"
|
|
set deptCode to "-KHCN_Missing"
|
|
|
|
-- Choose folder to create files
|
|
set targetFolder to choose folder with prompt "Select a folder to create the Missing files:"
|
|
|
|
repeat with n from 4121 to 4210
|
|
set fileName to baseDate & n & deptCode & ".txt"
|
|
set filePath to (targetFolder as text) & fileName
|
|
|
|
-- Create empty file
|
|
try
|
|
set f to open for access file filePath with write permission
|
|
close access f
|
|
on error
|
|
try
|
|
close access file filePath
|
|
end try
|
|
end try
|
|
end repeat
|
|
|
|
display dialog "Done! Files created from 2731 to 2779." buttons {"OK"} default button 1 |