If you are using the command button from the Controls toolbox, it
has an Enabled property that you can set from code:
Sheet1.CommandButton1.Enabled = True
--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
"Chris Gorham" wrote in
message
...
Thanks Chip on the first point...but not sure how to set the
Enabled property
on a button that resides on a worksheet...can do this no probs
if its on the
Userform
Chris
"Chip Pearson" wrote:
If you set the Style property of the combobox to
2-fmStyleDropDownList, the user can only select items from the
dropdown list; the user cannot enter other data in the
combobox.
To "grey out" a button, set the Enabled property to False.
--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
"Chris Gorham" wrote
in
message
...
Hi,
I'm using a combo box in a userform and using "Add Data" in
the
VBA code to
populate the drop down options...so far so good. However I'm
having
difficulty selecting the correct properites of the combo
box,
to prevent the
(human) user from selecting & editing the options in the
drop
down, when the
userform appears. Everything I try prevents the dropdown
from
actually,
well..dropping down.
Also, is it possible to disable or make invisible a button
on a
worksheet
when a condition arises (say a cell changes to a preset
value).
I can make
the button "grey out" or disappear on a UserForm, but I
can't
see how to do
it if it's on a worksheet. OK, I could set a condition in
the
code for it not
operate if pushed, but "greying out" would be neater.
Thanks...Chris