I love the Daily Journal template. I’m using it and planning on moving things out of Day One and into DevonThink and both moving away from a proprietary format and an additional subscription.
I’ve managed to move a copy of the template into the toolbar folder and add that to the toolbar so that I can easily press the button to add to my daily log.
But if I don’t have my “Personal” database highlighted in the sidebar, the template creates a new entry in whatever database I’ve been using last when I press the toolbar button.
I don’t know very much about apple scripting. I’d like to modify the properties of the DNtp variable so that the button creates in my “Personal” database which lives in my user/database/ folder. Could someone tell me how to do that? I’ve tried guessing and adding to the script, but it’s not working.
I’m not sure which script you mean. When I look at the source of the Journal entry template, I see only three RTF files (for English, French and German). And according to the documentation, this template is text-only, not script based.
Edit: I think I found what you’re referring to: Productivity/Journal? In that case, these two lines in the script might be of relevance
set myGroup to create location "/Journal/" & "/" & theYear & "/" & numMonth
set recordName to theYear & "-" & numMonth & "-" & theDay & " " & shortWeekday
From you post, I understand that the “Journal” group should always be located in your database “Personal”.
set myGroup to create location "/Journal/" & "/" & theYear & "/" & numMonth in database "Personal"
If you don’t like the name of the newly created record, you’d have to change the second line I quoted.
Disclaimer: I took this code verbatim from a script @pete31 posted some time ago. Since I’m not an AppleScript afficionado, I might have gotten that wrong.
You might want to check DT’s scripting dictionary in the Script Editor – always a good point of reference for scripting questions.
Bless you - that’s worked perfectly. I didn’t know I need to append the location line with “in database”
Made the change you suggested and it worked exactly like I wanted it to work.