Hiding control...

S

Sige

Hello All,

When using a control from the Forms toolbar (no ActiveX) ...eg a
checkbox ...

-How does one manage to hide also the control when hiding the row(s)
/column(s) on which you see teh control.
-Actually the question is more on how to fix a control to a certain
cell(s)! Not the "Cell link" but the control itself!
From the properties tab:
1. "Move and size with cells"is grayed-out
2. I used "Move but don't size with cells"... (which doesn't resize my
control by adjusting the cell height or width)
But this does not help... when Hiding the column in which the control
is...The control stays on top!

Cheers Sige
 
B

Bob Phillips

Here is a little sub that will hide a checkbox if it's top was in the passed
row

Sub HideControl(row As Long)
Dim checkbox

For Each checkbox In ActiveSheet.CheckBoxes
If checkbox.TopLeftCell.row = row Then
checkbox.Visible = False
End If
Next checkbox

End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top