Overriding SetThreadExecutionState

Posted by unixman83 on Stack Overflow See other posts from Stack Overflow or by unixman83
Published on 2011-01-04T21:42:14Z Indexed on 2011/01/04 21:54 UTC
Read the original article Hit count: 184

I am not sure if this belongs on serverfault or superuser.

I would like to override SetThreadExecutionState(ES_DISPLAY_REQUIRED) to be a no-op. How is this accomplished?

Is there some registry setting that can be altered instead of API hooking?

Blocking ES_DISPLAY_REQUIRED will prevent apps from keeping the monitor powered on. I have an application (likely the antivirus) that is preventing some monitors from entering power-save and I think this function is the culprit.

© Stack Overflow or respective owner

Related posts about Windows

Related posts about winapi