Is there a feature or method to DISABLE the apps window from displaying/sliding open when a script is executed via a button in a table? Or, is this a feature request? I’d just like it to run in the background when manually executed, like an automation.
The Script App and the Run Script action for Automations are very similar, but have certain functions that only work in one and not the other.
Making sure your script is compatible with Automations is not a one size fits all process. Generally, you have to adjust all your
input.somethings in some way since all Script App
inputs don’t work in Automations (and vice versa, the
inputs for Automations don’t work in Script App). For you, you likely have your button used with
input.recordAsync() to identify what record to update values for. Obviously that’s not going to work in an Automation, you’ll need to pass the appropriate record ID from the Automation’s trigger.
Also, none of the
output.somethings work in Automations (no one is there to read the output.)
The Scripting API documentation marks what functions work where.
You’re right that in my Button script I’m using input.recordAsync(), doing this:
let record = await input.recordAsync(‘Choose a record’, table);
Is there something about this that causes the script to run visibly in the side panel? That’s what I’d like to prevent somehow, I’d like it to run “silently” and just do it’s job.