Is there any property to hide the border of a xlGroupBox?

kishor_ys

New Member
Joined
Jun 12, 2008
Messages
7
Here is the sample code

Set sGroupBox = Sheets(1).Shapes.AddFormControl(xlGroupBox, _
Cells(1, 2).Left, Cells(1, 2 + 1).Top, 200, 16)
sGroupBox.TextFrame.Characters.Text = ""


which creates a group box with thin border.

Is there any property to hide the border of a group box?
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
This requires some faking, since Excel doesn't let us access the groupbox's border. You need your groupbox, a rectangle, and your option buttons. Draw the rectangle so it is slightly larger than the groupbox, give it a fill color to match the background, and remove its border. Set the stacking order of the objects so the group box is under all other objects, the rectangle is next, and all the buttons are on top.
 
Upvote 0
I just had the same problem and found this solution:

You dont need a macro, just a code.

Hit alt-f11 to get to the VBE
hit ctrl-G to see the immediate window

type this in and hit enter:
activesheet.groupboxes.visible = false

This hides all the groupboxes on the activesheet.

If you are running excel2007 it means you dont even need to save as a macro workbook, a regular file will do it.

Cheers!
 
Upvote 0

Forum statistics

Threads
1,215,064
Messages
6,122,936
Members
449,094
Latest member
teemeren

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top