I am trying to accomplish a simple task. Using the Action Import script and attaching it to a finder folder, anything that I put in the folder goes into my global inbox. What I need to do is modify the script so that whatever is put into the folder goes into a specific group of a specific database. The original script is:
on adding folder items to this_folder after receiving added_items try tell application id "com.devon-technologies.thinkpro2" to launch repeat with theItem in added_items try set theDatabase to open database "/Users/user/Library/Application Support/DEVONthink Pro 2/Databases/Medical.dtbase2" set thePath to theItem as text if thePath does not end with ".download:" then tell application id "com.devon-technologies.thinkpro2" to import thePath to incoming group end if end try end repeat end try end adding folder items to
I found the following lines in a post on these forums. However, whenever I try to add them into the script I get syntax errors.
set theDatabase to open database "/Users/user/Library/Application Support/DEVONthink Pro 2/Databases/To-Do_List.dtBase2" set theGroup to create location "/Projects/Active" in theDatabase
I’m completely new to scripting in general, and I thought I could figure this out on my own, but decreased time and increased frustration have not allowed me to do so. What do I need to add in order to have separate folders on my desktop import to specific databases/folders?