Can a custom module read and write to the clipboard of a Perspective client?

I found this answer on stackexchange about reading from the clipboard via a javascript API (at least I think it’s javascript…?)

Possible to bring this into Ignition via a module? I’d like to use the clipboard for some dev tools, as writing 100k+ rows of text into a Perspective text area is… not great… (or rather, it doesn’t; it crashes the browser)

It is indeed javascript,

It only works on some browsers and on some specific inputs. it also requires a prompt to be accepted.
Not really great for anything tbh, what are you trying to do?

You should proabbly use a file upload for such things

I’ve got some scripts that use tag browse to return tags and their info and to write back to tag properties. It’s fine using text field for <600ish tags, but any more and it dies. I can always run in script console instead, but would be super useful in a client where I can provide a gui for it. Reason to. Use clipboard as I’m lazy and don’t like saving to files and selecting them :sweat_smile:

1 Like

Creating a module just for this seems a lot more work :stuck_out_tongue:

I’m lazy for boring things, creating a module would be a good intro haha

4 Likes

Heh well, if perspective fails in a textarea i doubt the module would be different xd but the javascript part wouldnt be difficult.

You are just better off uploading files

The programmers creed “Never spend 6 minutes doing something by hand when you can spend 6 hours failing to automate it”

11 Likes

Only 6 hrs? :laughing:

3 Likes

I think 6 hours is the point where you give up and just end up doing it by hand anyways lol