PyScreeze is a simple, cross-platform screenshot module for Python 2 and 3.
Questions tagged [pyscreeze]
10 questions
3
votes
5 answers
Am using the pyautogui module now from Automate the Boring Stuff With Python. My code keeps telling me pyscreeze has no attribute locateOnWindow
import pyautogui
wh = pyautogui.size()
print(wh)
output:
locateOnWindow.__doc__ = pyscreeze.locateOnWindow.__doc__
AttributeError: module 'pyscreeze' has no attribute 'locateOnWindow'
Please I will be grateful for your Help.

Richlue Toure
- 31
- 1
- 3
3
votes
5 answers
Pyautogui and pyscreeze crash with windll.user32.ReleaseDC failed
I'm trying to compare certain pixel values in my pyautogui script, but it crashes with following error message after either multiple successful runs, or sometimes just straight on the first call:
Traceback (most recent call last):
File…

Nyxeria
- 363
- 1
- 4
- 12
2
votes
1 answer
PyAutoGUI was unable to import pyscreeze
my code:
import pyautogui
from time import sleep
x, y = pyautogui.locateOnScreen("slorixsh.png", confidence=0.5)
error:
Traceback (most recent call last):
File "", line 1, in
x, y = pyautogui.locateOnScreen("slorixsh.png",…

nugget 1
- 23
- 4
2
votes
2 answers
Python PyAutoGui pixelMatchesColor raises windll.user32.ReleaseDC Error
Been having issues trying to see if a pixel on my screen matches an RGB color. However, even after tweaking I could not get any good results. I looked it up online and tried different solution, but no luck.
Exception in thread Thread-2:
Traceback…

Ervin
- 75
- 1
- 10
1
vote
0 answers
How do I check the colour of a pixel?
Posting because the posts where this has been fixed are dead and the people maintaining the code haven't replied in months.
Traceback (most recent call last):
File "c:\Users\Combined_180222_desktop_version .py", line 510, in
…

mak47
- 303
- 2
- 14
0
votes
0 answers
Problem when running my bot to finding colors
I created a code couple days ago that was working perfectly, untill today when I got a problem running my code.
Problem:
Traceback (most recent call last):
File "C:\\Users\\pedro\\Downloads\\2023\\BOT.py", line 13, in \
fish =…
0
votes
2 answers
pyautogui / pyscreeze - locate works w/o region parameter, but doesn't work w/ region parameter
Using pyautogui, I'm trying to locate an image on screen.
This finds the image (on primary monitor w/ 2560x1440 resolution), but takes nearly 5 sec:
icon1 = pyautogui.locateOnScreen('[filepath]\\icon1.png', grayscale=True)
To reduce search time, I…

jub
- 377
- 1
- 2
- 14
0
votes
1 answer
PyScreeze Crashing: OSError: windll.gdi32.GetPixel failed : return -1
Trying to check the colour of a pixel:
while True:
x, y = 1742, 979
r,g,b = pyautogui.pixel(x, y)
if b == 106:
#some more code
The full traceback:
Traceback (most recent call last):
File…

mak47
- 303
- 2
- 14
0
votes
1 answer
Is it possible to pyscreeze.locate(needleImage, haystackImage): without reading haystackImage from a file each time?
I'm currently using PyAutoGUI for the locate function that searches a needleImage on a haystackImage. The example that the documentation provides takes in a path to the image. However, I have a function that compares a series of needleImage to a…

Matt
- 27
- 7
0
votes
1 answer
PyautoGUI can't locate on Screen, Pillow Issue [RESOLVED]
For some reason, I can't find on screen, the error looks like this;
Traceback (most recent call last):
File "C:\Users\centr\PycharmProjects\phoenix\whatsapp\main.py", line 7, in
position1 =…

GabsLeo
- 1
- 2