I have this script:
-- Import helper library
tell application "Finder" to set pathToAdditions to ((path to application id "DNtp" as string) & "Contents:Resources:Template Script Additions.scpt") as alias
set helperLibrary to load script pathToAdditions
-- Get the template file path.
set theTemplateFile to helperLibrary's pathToLocalizedResources() & "English Journal.md"
tell application id "DNtp"
-- Open the database.
set theDatabase to open database "/Users/John/Databases/Home.dtBase2"
-- Get a reference to the group I want.
set theLocation to create location "/Homeschool/English Journal" in theDatabase
-- Create the document based on the template file.
set entry to import theTemplateFile placeholders {something:"nothing"} to theLocation
-- Open the new document.
open tab for record entry
end tell
I now get a “missing value” result an the tab isn’t opened. When I log entry
it says “missing value”. It seems that import no longer returns the new entry.
Is this intentional, (so I should adjust my script to look for the latest entry and open that), or an oversight? The docs say that a Record object should be returned.