Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

How to exit the script?

New Here ,
Sep 02, 2008 Sep 02, 2008
How do I terminate the script - not Adobe application(s)?
exit(), quit()... - they don't work.

The only workaround I can think of is a main() function with "returns" in appropriate places, but I am just curious if there is a terminating command.

moniuch
TOPICS
Scripting
4.4K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Community Expert ,
Sep 02, 2008 Sep 02, 2008
If you're talking about a JavaScript then there's no command to exit the script. You can use the workaround you mentioned.

Edit: Deleted the alternative method that was here earlier... it's not really very good.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Sep 07, 2012 Sep 07, 2012

Bumbing!

Is there stil now way to exit Javascript as the workaround in question does not work in my scenerio!


// Clint

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Mentor ,
Sep 07, 2012 Sep 07, 2012

Don't shoot me Clint… but a word of advise… When scripting AI it is better to wrap your syntax in a function and call it… Bonus of this is return inside a function will stop it…

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Sep 10, 2012 Sep 10, 2012
LATEST

Your lucky! I wont shoot!

I solved it! What i wanted to do was to close the GUI when the script was done witch i now know is with w.close(); Thanks anyway!

// Mr Clint

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Sep 02, 2008 Sep 02, 2008
Yep, JS, forgot to mention.
Thanks for confirmation, I was afraid I RTFM with dusted eyeglasses ;-)
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines