Delphi – Taskbar width, height and position

delphi

I need to get the width and height of the taskbar. Also I need the position of the taskbar. How can I get this?

Best Answer

Depending on what you need that information for, you might want to look into Forms.TScreen.WorkAreaRect, because the work-area identified that way subtracts not only the TaskBar, but also any other "bar" that might limit available Desktop space.

You can simply use Screen.WorkAreaRect from your code, because a Screen: TScreen variable is declared in the Forms unit and initialized by the VCL.

Related Topic