Copy link to clipboard
Copied
How do I change the focus from any window to Illustrator using Extendscript? I have buttons in a panel that run scripts. When I click on them the current window focus changes to that panel. Unfortunately this means I have to manually click back into Illustrator to continue using Illustrator, which can be quite annoying.
try this
BridgeTalk.bringToFront("illustrator")
Copy link to clipboard
Copied
try this
BridgeTalk.bringToFront("illustrator")
Copy link to clipboard
Copied
Works perfectly. Thanks!
How did you know about this?
Copy link to clipboard
Copied
It's in the Illustrator Tools Guide.pdf
Copy link to clipboard
Copied
At one time I thought that creating a new palette and immediately closing it would work, but I think what ended up happening was that then I had both the (ScriptUI-based) script palette and Illustrator both out of focus! Let us know if Carlos' solution works for you.
Copy link to clipboard
Copied
oh good point, closing the window might yield a different result.