Results 1 to 4 of 4
  1. #1
    Join Date
    Dec 2003
    Posts
    5

    Unanswered: Shipping = Billing working but not visible

    I have a customer table with billing and shipping address and when the user clicks a check box to make shipping the same as billing, on a form, the information is stored correctly, via the form. However I would like to display the shipping address when they click the box rather than waiting until they leave add mode and go into view. I have the following code in the form VBA

    Private Sub Form_AfterUpdate()
    If Me!Check98 = True Then
    Me!SHADDRESS = Me!ADDRESS
    Me!SHADDRESS2 = Me!ADDRESS2
    Me!SHCITY = Me!CITY
    Me!SHSTATE = Me!STATE
    Me!SHZIP = Me!ZIP
    Me.RepaintObject
    End If
    End Sub

    Private Sub Form_Current()
    Me!Check98 = False

    End Sub

    It's got to be something simple I am overlooking. Thanks ahead of time for the help.
    Last edited by FOTH; 12-20-03 at 17:28.

  2. #2
    Join Date
    Nov 2003
    Location
    Warren, PA
    Posts
    52
    make sure your text box is the same name as the control source

    Example
    SHADDRESS - Both the name of the control and the control source should be SHADDRESS.

    Brent

  3. #3
    Join Date
    Dec 2003
    Posts
    5
    Yes they are and when the user exits the add routine the address is stored correctly in the customer table. It is just not showing in the add routine after they click the same as click box.

  4. #4
    Join Date
    Dec 2003
    Posts
    5
    Aight I figured it out and decided to post the fix. I needed to put the code in the "check_afterupdate rather than the form_afterupdate and remove the me.repaint. Works like a champ now.

Posting Permissions

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