Simple question, how to I get the current height of the Windows Taskbar?
-Thanks;)
Printable View
Simple question, how to I get the current height of the Windows Taskbar?
-Thanks;)
You can get the screen width and height:
Then get the active work area (without taskbar) passing the as a parameter to SystemParametersInfo and substract it from the entire width. The remainder is the taskbar height.Code:width = (GetSystemMetrics(SM_CXSCREEN)
height = GetSystemMetrics(SM_CYSCREEN)
Note: Maybe there is a much simpler way!:confused:Code:SPI_GETWORKAREA Retrieves the size of the work area on the primary display monitor. The work area is the portion of the screen not obscured by the system taskbar or by application desktop toolbars. The pvParam parameter must point to aRECT structure that receives the coordinates of the work area, expressed in virtual screen coordinates.
To get the work area of a monitor other than the primary display monitor, call theGetMonitorInfo function.
Thanks. Know how to change the active work area?