2

I'm trying to paste in a txt block but I always get an error no matter how hard I try

the copy part is already resolved but pasting in a txt not yet

import pyperclip

with open('conta.txt', 'w+') as f:
    conteudo = f.write()
    pyperclip.paste(str(conteudo))
Daniel Walker
  • 6,380
  • 5
  • 22
  • 45
Gustavo
  • 33
  • 5

1 Answers1

2

Think it's more like this:

import pyperclip

with open('conta.txt', 'w+') as f:
    f.write( pyperclip.paste() )
Doyousketch2
  • 2,060
  • 1
  • 11
  • 11