Hello, I’m having problems trying to make a text file inside a newly created folder. I’m getting the “You don’t have permissions…” I’ve tried several different approaches but still can’t get the text file to save on the new folder created.
This is what I have so far. This is the last of many tries before I gave up and came here asking for help, I tried shell script, textedit etc, but I’m not having any luck.
Thanks for your help, really appreciate it.
set theContent to "djdklsfjklewjfiorjsdlndsklfjkld"
set thePath to (path to desktop as text) & "HD:User:etc:Job Files:1-New Jobs:"
set theSubject to "subject"
tell application "Finder"
make new folder at thePath with properties {name:theSubject}
end tell
tell application "TextEdit"
--activate
make new document
--set name of document 1 to theSubject
set text of document 1 to theContent as text
save document 1 in (path to desktop as text) & "test.txt"
close
end tell