Vba – Draw border around controls on VBA Userform without using a Frame

userformvba

I am designing a VBA UserForm (in Excel, if it is relevant) and I would like some controls to be visually grouped together.. but when I put them in a frame, I am getting some undesired results (part of it has to do with the RefEdit control which seems to be particularly unhappy inside a frame).

Is there a way to draw a border around a group of controls on a form without putting them inside a Frame?

Best Solution

Use a label with the caption deleted and the border style set to fmBorderStyleSingle. It may appear on top of your other controls, so right click on it and select "send backwards" until it's behind your other controls.

Related Question