Results 1 to 8 of 8
  1. #1
    New Lounger
    Join Date
    Dec 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Trigger Form Controls (2003)

    I need to trigger a Check Box on a main form based the records "Status" on a subform. When the user selects either "Verified or Changed" the "Closed" check box should be on and when there are three records with a "Not Verified" status on the subform the "Closed" check box should be on. Please see the attached sample DB.

    Please help.
    Thanks
    Nat

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Trigger Form Controls (2003)

    Welcome to Woody's Lounge!

    Your description doesn't seem to leave much room for the check box on the main form to be off. What are the situations in which it should be off?

  3. #3
    New Lounger
    Join Date
    Dec 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Trigger Form Controls (2003)

    Only when the "Not Verified" status is selected on the subform but when there are 3 records for a customer then the closed check box should be on.

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Trigger Form Controls (2003)

    Sorry to be so dense, but I don't understand. You'll have to explain it very precisely and in detail.

  5. #5
    New Lounger
    Join Date
    Dec 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Trigger Form Controls (2003)

    I hope this helps:

    OK. The

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Trigger Form Controls (2003)

    OK, thanks, now it is much clearer. See the attached version. I have added VBA code in two places:
    - In the On Current event of the main form, to update the check box as the user moves from record to record.
    - In the After Update event of the subform, to update the check box when the user changes the status of a call.

    In my next reply, I'll demonstrate another approach.

  7. #7
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Trigger Form Controls (2003)

    In this version, I removed the Closed field from the tbCusTracking and replaced it with a calculated field in a query that acts as record source for the main form.
    Code in the After Update event of Status on the subform forces the main form to recalculate.

  8. #8
    New Lounger
    Join Date
    Dec 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Trigger Form Controls (2003)

    I think I will use Sample2. Thanks!

Posting Permissions

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