Skip to content
Advertisement

copy and paste in selenium python

I’m new to selenium I am trying to copy something from one page to another, the page that I copy off of already has it so if you just click on the text once it copies automatically but it is not copying anything I am not sure why

JavaScript

Advertisement

Answer

On my Linux in Firefox and Chrome works

JavaScript

Like

JavaScript

I tried to test it with your code but you use xpath which I can’t find on Instagam

So I tested with field Search... on current page

JavaScript

BTW: I described this long time ago in

Selenium: How to send clipboad to field in browser — furas.pl.

I show also how to use module pyperclip to work with clipboard.

JavaScript
User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement