Microsoft Communities

Welcome to WindowsClient.net | Sign in | Join

Here are some frequently asked questions about Windows Forms and their answers.

Windows Forms FAQs

How do I determine the height and width of the non-client region (e.g., the border in a TextBox) of a control?

One generic way for all controls is to get the difference between the ClientRectangle's width and the Control.Bounds' width. That should give the border width (and in general the non-client area width). Use the same approach for height.

Contributed from George Shepherd's Windows Forms FAQ



Page view counter