Copy text to clipboard while dialog is open (via script)
Hi,
I have a JavaSript script that shows a dialog.
While that dialog is still open, I want to copy some string to the clipboard.
I've tried adding a dummy text frame with that string as its content, selecting the content, and invoking app.copy(). But that doesn't work.
I think the reason it doesn't work is that the open dialog prevents adding a new text frame.
Do you have a solution?
Two possibly important details:
If I could access the clipboard directly, that would be fine. The reason behind the above-mentioned method is that it seems there's no direct access to the clipboard.
I need the script to tun on both macOS and Windows.
Thanks!
