Listbox's, .Enabled and .Visible do not work

G

Guest

I do not see why this will not work.
'================
If CheckBox1 = True Then
ListBox1.Visible = False 'Use Visible or Enabled, neither work
'code here
end if
'=============
When this works fine
'=============
If CheckBox1 = True Then
CheckBox2.Visible = False
CheckBox3.Visible = False
End If
'=============

Thanks in advance!
--
Regards

Rick
XP Pro
Office 2007
 
G

Guest

Rick S,

If on a form try Userform1.listbox1.visible=false
If on a worksheet then Sheets("sheet1").listbox1.visible=false
 
G

Guest

Yes it is on a Form and "Userform1.listbox1.visible=false" did not work either?

I can use the toolbox, set the visible value to False then load the form and
it is not visible. I just can't do it in a macro.

On the opposite side, I can not make the listbox visible if I turn it off
from the toolbox.

Crazy man! The whole world is crazy!

--
Regards

Rick
XP Pro
Office 2007
 
G

Guest

Problem solved!
I simply had to pull my head from out of my behind!
The code was in the wrong part of the macro to know when the event occured.

Please keep the laughter to a dull roar, I still have work to do! ;)

--
Regards

Rick
XP Pro
Office 2007
 

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