Checkbox

  • Thread starter Thread starter Mikeymay
  • Start date Start date
M

Mikeymay

I have a Checkbox within a form and when checked I want a
Textbox to be available to accept some data. How do I do
this while the form is still open and no buttons have been
pressed to accept the data entered.

Also if the Checkbox is unchecked I don't the user to be
able to input data into the textbox and to have it 'greyed-
out'.
 
Hi,

This will enabled and disable the textbox whenever the checkbox is clicked.

Private Sub CheckBox1_Click()
TextBox1.Enabled = Not CheckBox1.Value
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

Back
Top