Command Button

  • Thread starter Thread starter Bill
  • Start date Start date
B

Bill

Morning,

I have a form that contains a combo box and three command
buttons. What I would like to do is have two of the
three command buttons disabled until an item is selected
in the combo box. The third command button would be
active. This button is a "Cancel" button.

Anyone have any idea how to do this?

Thanks
 
Bill said:
Morning,

I have a form that contains a combo box and three command
buttons. What I would like to do is have two of the
three command buttons disabled until an item is selected
in the combo box. The third command button would be
active. This button is a "Cancel" button.

Anyone have any idea how to do this?

In the AfterUpdate event of the ComboBox...

Me.CommanButton1.Enabled = Not IsNull(Me.ComboBoxName)
Me.CommanButton2.Enabled = Not IsNull(Me.ComboBoxName)

The buttons should default to disabled of course.
 

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

Back
Top