Alex Dana
Alex Dana

Reputation: 1287

How to write filepath on PyAutoGUI

I'm using PyAutoGUI to type this filepath :

 pyautogui.write(r'C:\Users\Alex\Dropbox\PythonDev\Instagram\imagename.jpg', interval=0.1)

However, despite the fact there is "r'" in the beginning of my code, i still have a problem :

enter image description here

How can I avoid this problem ?

Upvotes: 2

Views: 1255

Answers (1)

EasyWay Coder
EasyWay Coder

Reputation: 341

You can try the following pyautogui.write('C:\\Users\\Alex\\Dropbox\\PythonDev\\Instagram\\imagename.jpg', interval=0.1)

OR

pyautogui.typewrite("C:\\Users\\Alex\\Dropbox\\PythonDev\\Instagram\\imagename.jpg", interval=0.1)

Upvotes: 2

Related Questions