I want to write a program that will run a few lines on any piece of data or string upon copying to clipboard, is there a way to do this? I cant find much information about it.
Asked
Active
Viewed 39 times
0
-
1Does this answer your question? [Trigger an event when clipboard content changes](https://stackoverflow.com/questions/14685999/trigger-an-event-when-clipboard-content-changes) – noah1400 Jul 20 '22 at 20:13
-
https://abdus.dev/posts/monitor-clipboard/ – PM 77-1 Jul 20 '22 at 20:13
1 Answers
1
I found https://pyperclip.readthedocs.io/en/latest/index.html
It has the pyperclip.waitForPaste()
function, which should do exactly what you want. I had issues trying it with Linux Fedora, but it should be no problem on most Systems.

einekratzekkatze
- 81
- 6