Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2011

    Unanswered: Multiple Condition If Then... possible?

    Is it possible to perform multiple onclick or afterupdate events on checkbox option frames where (for example) if frame20 is 'yes' (1) and frame21 is also 'yes' then textbox22 is disabled?

  2. #2
    Join Date
    May 2005
    Nevada, USA
    Provided Answers: 6
    Not clear on the question, but you can certainly have:

    If Me.Frame20 = 1 And Me.Frame21 = 1 Then

  3. #3
    Join Date
    Aug 2004
    Cary, NC
    I'm also not positive what you are asking but I'm going to add a couple observations just the same....

    Why do you have option frames with yes/no choices in them instead of using a checkbox that is inherently yes/no? The danger with using a frame and then testing the value for a condition, is it depends on the option values of the controls in the frame. A checkbox however, will always return the same values, 0 for unchecked and -1 for checked (or null if you have triple state set to true)

    You can then safely use these values to test for conditions. Since they are numbers you can even use them directly if you care to.

    The following statement would enable the text box if both checks are true and disable it otherwise (with Triple State = No). You can just put it in the after update event of your checkboxes.

    textbox22.enabled = check1 * check2
    Then again, I could be way off from what you are asking!


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts