Re: BUG? AppleScript do script in standalone broken?
Posted: Fri Apr 27, 2018 2:29 am
Well the problem I was having was a bug but has since been determined to be the new default behavior by the LC team, it's been changed to a feature request to add a checkbox to the standalone settings to include the Applescript dictionary or not (though you can already supply a custom .plist file and include other files in LC 9's standalone settings).
That's all completely unrelated to ekami's problem. That, I think, is probably something to do with the way the engine loads at "on startup" and so the work around seems to be add a delay to make sure everything is loaded before trying to execute AppleScript. You could try moving the AppleSCript into the card script and see how that is. Another option is to use the shell() function along with osascript cli to run AppleScripts, which opens up a few more tricks (like on-the-fly compiling standalone AS applets).
That's all completely unrelated to ekami's problem. That, I think, is probably something to do with the way the engine loads at "on startup" and so the work around seems to be add a delay to make sure everything is loaded before trying to execute AppleScript. You could try moving the AppleSCript into the card script and see how that is. Another option is to use the shell() function along with osascript cli to run AppleScripts, which opens up a few more tricks (like on-the-fly compiling standalone AS applets).