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

Dumb question : how to create a button to launch mu script ?

Explorer ,
Jan 31, 2023 Jan 31, 2023

Hello, I am a newby in scripting for AE so this is surely a dumb question...

I have an issue : when I install my .jsx scrip in \ScriptUI Panels I can launch it through the window panel in AE, thats nice.

But my problem is that it opens an empty dockable panel with the same name than my script... 
Do you guys have an idea on how to create a button in that empty panel (and not in a new one) that would launch my script ?

Thanks !

TOPICS
Error or problem , Expressions , Scripting
795
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

correct answers 1 Correct answer

Enthusiast , Jan 31, 2023 Jan 31, 2023

When a script is launched as a panel, AE provides the panel. So you have to build your UI into that panel rather than just creating a new window like you would if launched from the File > Scripts menu.

 

Here are a couple of examples that check if the script received a panel, using that if so, otherwise creating a new window. I'm sure I've posted a framework like this on here in the past, and probably countless others too, so there should be plenty of examples to find.

 

https://medium.com/@andreipopa191187/easiest-way-to-create-a-dockable-panel-in-adobe-after-effects-a9791d2e012a

https://www.goodboy.ninja/blog/the-secret-to-a-dockable-scriptui-panel

...
Translate
Enthusiast ,
Jan 31, 2023 Jan 31, 2023

When a script is launched as a panel, AE provides the panel. So you have to build your UI into that panel rather than just creating a new window like you would if launched from the File > Scripts menu.

 

Here are a couple of examples that check if the script received a panel, using that if so, otherwise creating a new window. I'm sure I've posted a framework like this on here in the past, and probably countless others too, so there should be plenty of examples to find.

 

https://medium.com/@andreipopa191187/easiest-way-to-create-a-dockable-panel-in-adobe-after-effects-a...

https://www.goodboy.ninja/blog/the-secret-to-a-dockable-scriptui-panel

 

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
Explorer ,
Jan 31, 2023 Jan 31, 2023

Okay thanks ! That was fast 🙂

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
Explorer ,
Mar 01, 2023 Mar 01, 2023
LATEST

Thank you! it was really helpful!

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