Need help with SystemParametersInfo (setting desktop work area)
-
Hello ! I'm using SystemParametersInfo API to set desktop work area so 25 pixels on top are free... I do it like this : SystemParametersInfo(SPI_SETWORKAREA, Nothing, area, SPIF_UPDATEANDSEND) where SPIF_UPDATEANDSEND = SPIF_UPDATEINIFILE Or SPIF_SENDWININICHANGE and everything works! then my program is closed ... and everything stays that way for like 5 minutes. Then work area is restarted to full screen ... What can I do so work area that I set will be remembered at least until reboot ? thanks :)
-
Hello ! I'm using SystemParametersInfo API to set desktop work area so 25 pixels on top are free... I do it like this : SystemParametersInfo(SPI_SETWORKAREA, Nothing, area, SPIF_UPDATEANDSEND) where SPIF_UPDATEANDSEND = SPIF_UPDATEINIFILE Or SPIF_SENDWININICHANGE and everything works! then my program is closed ... and everything stays that way for like 5 minutes. Then work area is restarted to full screen ... What can I do so work area that I set will be remembered at least until reboot ? thanks :)
xx77abs wrote:
and everything stays that way for like 5 minutes. Then work area is restarted to full screen ... What can I do so work area that I set will be remembered at least until reboot ?
Keep your code running. Once your code stops, that's it, the area you reserve is returned to the desktop.
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007, 2008 -
xx77abs wrote:
and everything stays that way for like 5 minutes. Then work area is restarted to full screen ... What can I do so work area that I set will be remembered at least until reboot ?
Keep your code running. Once your code stops, that's it, the area you reserve is returned to the desktop.
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007, 2008