Aug-27-2018, 08:38 AM
hello all ...
i write a code to take 10 screenshot from the desktop and save them to file but i need to save them in this format :
qan-2018-08-27 04:03(0)
qan-2018-08-27 04:03(1)
qan-2018-08-27 04:03(2)
...
this is my code :
i write a code to take 10 screenshot from the desktop and save them to file but i need to save them in this format :
qan-2018-08-27 04:03(0)
qan-2018-08-27 04:03(1)
qan-2018-08-27 04:03(2)
...
this is my code :
import pyautogui import datetime q = datetime.datetime.now() d= q.strftime("%Y-%m-%d %H:%M") x = 0 while x<10: pic = pyautogui.screenshot(r'C:\Users\root\Desktop\test\qan-'+str(x)+'.png') x+=1how i cant add ( d ) here : qan-'+str(x)+'.png'