ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Lines user forms (https://www.excelbanter.com/excel-programming/425291-lines-user-forms.html)

Ken

Lines user forms
 
Does anyone know if it is possible to add lines or boxes to dress up user
forms?
Thanks in advance

Tom Hutchins

Lines user forms
 
You can do both with labels. For a box, add a label with no text. Set its
backstyle to transparent but with a visible border. If it's going to enclose
other controls, put the label box in place first or send it to the back, so
it doesn't keep the other controls from getting the input focus. For a
horizontal line, add a label with no text and a height of 1 (or 2). For a
vertical line, add a label with no text and a width of 1 (or 2). You can
change the "line's" color using its BorderColor property. Also, if you
wanted, you could make use of the label's events (click, double-click, etc.)

Hope this helps,

Hutch

"Ken" wrote:

Does anyone know if it is possible to add lines or boxes to dress up user
forms?
Thanks in advance


Ken

Lines user forms
 
Thanks, couldn't see what was right in front of me.

"Tom Hutchins" wrote:

You can do both with labels. For a box, add a label with no text. Set its
backstyle to transparent but with a visible border. If it's going to enclose
other controls, put the label box in place first or send it to the back, so
it doesn't keep the other controls from getting the input focus. For a
horizontal line, add a label with no text and a height of 1 (or 2). For a
vertical line, add a label with no text and a width of 1 (or 2). You can
change the "line's" color using its BorderColor property. Also, if you
wanted, you could make use of the label's events (click, double-click, etc.)

Hope this helps,

Hutch

"Ken" wrote:

Does anyone know if it is possible to add lines or boxes to dress up user
forms?
Thanks in advance



All times are GMT +1. The time now is 08:16 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com