Is there a way to get the text from a player's clipboard?

someone ples answer im curious
and if there is a way pls tell because its useful in what im trying to make :slight_smile:

(sorry if I’m not helping) There is something a bit similar where you can install a file on another person’s pc (which is quite dangerous though)

what the… just why and how would that even be possible?!

Greetings,

Thanks for writing in with you question! In Game Lab, there is no way that you can read the data that is stored on a user’s clipboard. Since users can have just about anything stored in their clipboard-- their password, bank account number, favorite brand of ramen noodles-- it would pose a security risk to be able to access this data. There is an expectation of privacy when we store data on our own computers. While there are malicious files and actors who seek to steal data, there are huge issues with ethics and legality when it comes to these practices.

I wonder if there is a way that you can get useful information from users in your application without the use of reading their clipboard? Perhaps you can try reading keyboard inputs or have them respond to a choice that you present.

Keep on creating!
Erik

That would basically be prompt(“text here”);

In App Lab, simply use an input and have them press Ctrl+V.

In Game Lab, you could have it check if both “ctrl” and “v” are being pressed, and then have it prompt for what they want to paste.

var input = "";
function draw() {
  if (keyDown(CONTROL) && keyDown("v")) {
    input = (prompt("Paste:") || input); // doesn't change if they press "cancel"
  }
}

It’s possible I’ve done it before.