Skip to main content
Participant
August 20, 2013
Question

How to Link After Effects Buttons/Interface to Scripts?

  • August 20, 2013
  • 2 replies
  • 1259 views

Hey, guys.

I'm trying to write a script that displays certain messages when a caertain button is pressed in After Effects itself (not buttons in my script). I was wondering if there was a way to, for example, display "This is a button" when I click on the render button. Does anyone know if this is possible with the tools provided in ExtendScript Toolkit CS6?

Thank you.

This topic has been closed for replies.

2 replies

Participant
August 30, 2013

Sorry, maybe I wasn't as specific as I could have been. I want the script te be able to recognize that a certain button (not necessarily the render button) is being pressed and show a corresponding pop-up. It appears as though I cannot do it with a script alone, but a plug-in must be involved in some way. I hope this clears things up if you think you still might have some ideas. Thanks again.

Lazlo_Hollyfeld
Inspiring
August 31, 2013

Yeah, I don't think it's possible, even if you were to write a C++ plugin with the SDK.  You could definitely detect when buttons are pressed with you wrote a plugin, or even a ScriptUI plugin.  As for attached event listenters to core AE ui elements, I cannot think of a way to do that off the top of my head. . . if I think of something that could work, I'll definitely post.  Maybe you can be more specific as to what you are trying to acheive if you could do that.  Why do want to detect clicks on ui elements that are part of the standard AE ui?

Lazlo_Hollyfeld
Inspiring
August 26, 2013

I don't think you can latch onto those events, althought I might be wrong.  You might be able to have a function execute at specific intervals to check and see if the app is rendering.  Once you detect it is rendering, you can clear the interval, cancel the rendering process, and call the function you want.  All this probably consumes more memory than necessary, but it could work.  If you try it, please let us know.