ACCESS - can i display a field if a condition is met in another fi

  • Thread starter Thread starter SuzyQ2k
  • Start date Start date
S

SuzyQ2k

using 2003 ACCESS Professional - need to have a form with a check box. If it
is checked another field will display or activate.
 
Use the checkbox's AfterUpdate or Clicked event. You can enable/disable
another control (based on whether the checkbox is checked or not), or you
can make another control visible/invisible with that control's Visible
property.

If you also want this to happen when an existing record is displayed in the
form, use the form's Current event, same code as in the checkbox's event.

Carl Rapson
 
SuzyQ2k -

Yes, you can do this. You should put this code in the On Click event for
your checkbox (use your control names):

Me.fieldName.visible = Me.CheckboxName.Value

Depending on the use of the form, you may want to set the control with the
field to be invisible by default, and only display it if the checkbox is
checked. If this is a form used to view existing records as well as adding
new records, then you will want to add the above code to the On Current event
of the form as well, so it adjusts while scrolling between records.
 
Back
Top