-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"No enumerators available" - on Windows 10 #30
Comments
Do you get this error on older versions of screeninfo? Would you mind sharing what values the variable dc_full gets? |
I'm not reproducing this issue on Win10 with Python 3.8.1. |
This is the only version of screeninfo I have tried and on Python 3.7.3. I've worked around the issue in the application that was failing for me. However, looking at this again I can see a few problems. Rectifying them fixes the issue for me.
|
Thanks for looking into it. Would you mind posting your changes so I could test them? Or submit a PR? Since I can't reproduce the problem I can't do more right now. |
Fixes rr-#30 dc_full is a pointer, if interpretted as a signed number may be negative. Null -> 0 indicates failure. Set return types for foriegn function so return value can be compared to None. ReleaseDC was not being called with enough arguments, it should also take the same Window Handle (HWND) as GetDC.
Getting a
No enumerators available
error.The exception being raised in
get_monitors
isThis is coming from the
EnumDisplayMonitors
call inenumerators\windows
Originally posted by @feerrenrut in https://github.com/rr-/screeninfo/issues/27#issuecomment-611994044
The text was updated successfully, but these errors were encountered: