Help with VB Code to open a popup window on the "After Update" event

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Del

    Help with VB Code to open a popup window on the "After Update" event

    I have a database that is used to process customer orders. This
    databse has numerous tables and forms the table involved in this
    question is called tblCustomerMast er. There are two forms in question
    one called frmReviewOrder, and the other called frmCreditHold

    On the tblCustomerMast er table there is a check box for credit hold.
    This is used to signify a customer that is not allowed to order goods
    because of some credit issue.

    On the frmReviewOrder form there is a drop down combo box for the
    Customer's ID number, called CustNbr. Once the user selects the
    Customer Number from the drop down I would like Access to look up that
    CustNbr at the tblCustomermast er table and if the CreditHold check box
    is True them I want the frmCreditHold form to open. If the creditHold
    check box is false (not checked) I want Access to continue on (Do
    nothing).

    Thank you for any assistance!

    Regards,
    Del
  • Ruskin

    #2
    Re: Help with VB Code to open a popup window on the "After Update" event

    Try something like;

    Private Sub cboCustomer_Cli ck()
    If DLookup("[Credit Hold]","tblCustomerM aster", _
    "[Customer ID]='" & cboCustomer & "'") Then
    DoCmd.OpenForm "frmCreditHold" , acNormal, , , , acDialog
    End If
    End Sub


    "Del" <dtlabo@yahoo.c om> wrote in message
    news:c2f38125.0 404051137.754b7 827@posting.goo gle.com...[color=blue]
    > I have a database that is used to process customer orders. This
    > databse has numerous tables and forms the table involved in this
    > question is called tblCustomerMast er. There are two forms in question
    > one called frmReviewOrder, and the other called frmCreditHold
    >
    > On the tblCustomerMast er table there is a check box for credit hold.
    > This is used to signify a customer that is not allowed to order goods
    > because of some credit issue.
    >
    > On the frmReviewOrder form there is a drop down combo box for the
    > Customer's ID number, called CustNbr. Once the user selects the
    > Customer Number from the drop down I would like Access to look up that
    > CustNbr at the tblCustomermast er table and if the CreditHold check box
    > is True them I want the frmCreditHold form to open. If the creditHold
    > check box is false (not checked) I want Access to continue on (Do
    > nothing).
    >
    > Thank you for any assistance!
    >
    > Regards,
    > Del[/color]



    Comment

    • Del

      #3
      Re: Help with VB Code to open a popup window on the &quot;After Update&quot; event

      Worked like a champ.

      Thank You!!!

      Del

      "Ruskin" <ruhardie@nospa m.xtra.com> wrote in message news:<uhjcc.627 1$d%6.110658@ne ws.xtra.co.nz>. ..[color=blue]
      > Try something like;
      >
      > Private Sub cboCustomer_Cli ck()
      > If DLookup("[Credit Hold]","tblCustomerM aster", _
      > "[Customer ID]='" & cboCustomer & "'") Then
      > DoCmd.OpenForm "frmCreditHold" , acNormal, , , , acDialog
      > End If
      > End Sub
      >
      >
      > "Del" <dtlabo@yahoo.c om> wrote in message
      > news:c2f38125.0 404051137.754b7 827@posting.goo gle.com...[color=green]
      > > I have a database that is used to process customer orders. This
      > > databse has numerous tables and forms the table involved in this
      > > question is called tblCustomerMast er. There are two forms in question
      > > one called frmReviewOrder, and the other called frmCreditHold
      > >
      > > On the tblCustomerMast er table there is a check box for credit hold.
      > > This is used to signify a customer that is not allowed to order goods
      > > because of some credit issue.
      > >
      > > On the frmReviewOrder form there is a drop down combo box for the
      > > Customer's ID number, called CustNbr. Once the user selects the
      > > Customer Number from the drop down I would like Access to look up that
      > > CustNbr at the tblCustomermast er table and if the CreditHold check box
      > > is True them I want the frmCreditHold form to open. If the creditHold
      > > check box is false (not checked) I want Access to continue on (Do
      > > nothing).
      > >
      > > Thank you for any assistance!
      > >
      > > Regards,
      > > Del[/color][/color]

      Comment

      Working...