I’ve got an AppleScript tool that creates the various elements of projects for a certain tool I use.
If I hard-wire the path to the folders, the script works great. If, however, I include an option to “select folder” for data I need to use and include a default starting point, it fails.
Here are the snippets:
#set tm_location to "/Users/bowjest/01 Level/03 Level/10 Level"
set tm_location to choose folder with prompt "TM folder :" default location "/Users/bowjest/01 Level/03 Level/10 Level"
#set glossary_location to "/Users/bowjest/01 Level/03 Level/11 Level"
set glossary_location to choose folder with prompt "Glossary folder :" default location "/Users/bowjest/01 Level/03 Level/11 Level"
If I don’t include the default starting point, it completes the project with no problems. But if I include a default starting point (as above), it produces the following path info in the project:
/Users/bowjest/Desktop/PROJECT/Macintosh HD:Users:bowjest:01 Level:03 Level:10 Level:01 Data:/
The project software can’t cope with the colons that are inserted. If no default starting point is specified, no colons are inserted (but then I have to navigate through a lot of layers of folders, hence my desire to have a default starting point).
Does anyone see where I may have gone wrong? I’ve tried everything I can think of, but so far can’t get this to work.
Thanks