In my service I need to issue a "refresh" after changing the logon screensaver timeout. While doing research, I kept finding references to UpdatePerUserSystemParameters
API. This API seems to be present in user32.dll
but I can't find out what exact does it do? (Well, besides literally reading its name.) Any suggestions?
It was/is(?) a way for forcing the OS to refresh certain system settings by re-reading the relevant registry keys. In particular for colour schemes or desktop backgrounds. So it meant that you could change e.g. the Windows desktop wallpaper by merging a .reg file into the registry and then executing UpdatePerUserSystemParameters
from user32.dll to make it read and apply the changed entries.
As the post you linked dictates, the SystemParametersInfo
function is the correct way to change system parameters, and this must be done programatically rather than via a registry hack and a forced refresh from a .bat file.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With