Tinderbox Forum

exportedStr() workaround in AppleScript?

I can see there’s a note in the Expressions page in the Cookbook informing exportedStr() is broken for now.

Indeed, this will return an empty string with Tinderbox 8.7.1:

tell application "Tinderbox 8"
	repeat with aNote in front document's selections
		set exportedStr to evaluate aNote with "exportedStr(this, /Templates/PHI HTML note)"
	end repeat
end tell

Is there any workaround to get the formatted $Text in AppleScript (or maybe I’m not using evaluate correctly)?

That version of Cookbook addresses Tinderbox 7.3.2 – long time ago.

Is this correct?

set exportedStr to evaluate aNote with "exportedStr(this, /Templates/PHI HTML note)"

or should it be

set exportedStr to evaluate aNote with "exportedStr(this, '/Templates/PHI HTML note')"

???

Hello @PaulWalters. The problem was misreading the documentation :man_facepalming:
The expression is actually exportedString()

1 Like