cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

try/catch/finally in scripting

try/catch/finally in scripting

It would be great to be able to use try/catch/finally statements in server-side scripting. 

 

try {

   // do something complex

} catch(err) { 

  Logger.log(err.message);

} finally {

  Logger.log('here you can clean up things afterwards');

}

3 Comments
gasevsm
Alumni

I support this, looking into it.

john.denner
Advocate

Still waiting on this. 🙂 Just tried to implement this error handling method when attempting to perform a workflow transition by custom ID. 

loic_guilloux_GE
Enthusiast

That's a great idea to avoid the default error message...

Can't find what you're looking for? Ask the community or share your knowledge.

Submit Idea