The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: dedndave on March 07, 2011, 03:13:32 PM

Title: Screen Resolution Notification
Post by: dedndave on March 07, 2011, 03:13:32 PM
which notification (message) tells us if the user changes screen resolution ?
Title: Re: Screen Resolution Notification
Post by: donkey on March 07, 2011, 03:24:10 PM
Probably WM_SETTINGCHANGE though I'm not sure if resolution is covered by that one.
Title: Re: Screen Resolution Notification
Post by: Tedd on March 07, 2011, 03:32:10 PM
All top-level windows receive WM_SETTINGSCHANGE when any of the SystemParametersInfo values changes.
While it doesn't strictly give the screen resolution, SPI_GETWORKAREA gives the usable desktop area which should be what you're actually interested in.

WM_SETTINGCHANGE -- http://msdn.microsoft.com/en-us/library/ms725497%28v=VS.85%29.aspx
SystemParametersInfo -- http://msdn.microsoft.com/en-us/library/ms724947%28VS.85%29.aspx
Title: Re: Screen Resolution Notification
Post by: dedndave on March 07, 2011, 03:36:08 PM
thanks guys

i found it...

WM_DISPLAYCHANGE

i made my program display the message values, then changed resolution and went through the list   :P