Results 1 to 3 of 3
  1. #1
    Platinum Lounger
    Join Date
    Feb 2002
    Location
    A Magic Forest in Deepest, Darkest Kent
    Posts
    5,681
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Add records to multiple tables from one combo

    Hi There

    It is a bit difficult to do this without the table structure of your database and just a snapshot of the form but I will make the following assumptions:

    1) The three combos are each attached to a seperate related look up table (Table1, Table2 and Table3)
    2) When a record is created these fields are going into a table bound to the form (call it TableA)

    When I teach this particular thing to my students I get them to create a make table query from TableA that takes the unique record from the Product Field ( you can repeat this method for the other two look ups)

    Say the look up table for the Products look up is going to tableA create the make table query so that it makes a table called TableA and when it is written it will overwrite the table and when you re-open the form the look up will be updated.

    If you are unsure of this short explanation could you reply to this thread with a stripped down version of your database with any private date removed and we will have a look for you. I ask this as you may have a different design that may not work with this method.
    Jerry

  2. #2
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Ephrata, Washington, USA
    Posts
    683
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Add records to multiple tables from one combo (2003)

    Edited by HansV to reduce overly large screenshot in size

    One of my coworkers made a database and she asked me to help her with
    it. She currently has 3 tables: Category, Product and Manufacturer
    Name.

    She has a form in which she created a drop down list for Product. She
    wants the Manufacturer and Category information related to that product
    to be displayed. AND, if the product isn't in the list, she wants to add
    it on the fly and add the Manufacturer and Category information for that
    product to each of those 2 fields and have their respective tables
    updated so that next time she clicks on the Product drop down, that
    information will be there.

    I've attached a print of her form for you to see what she has done.

    I am very green when it comes to VBA, so please, if you give me code,
    tell me how to use it.

    Thank you!!

    Thank you!!
    Attached Images Attached Images
    • File Type: gif x.gif (4.1 KB, 1 views)

  3. #3
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Ephrata, Washington, USA
    Posts
    683
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Add records to multiple tables from one combo

    Thank you, Jerry. I'm attaching the db so you can take a look at it. The form in question is the Inventory form. It's not my db, so I'm not at liberty to really change the structure. I took a look at it and would like to change some things, but the user said there is too much data for her to be comfortable changing the structure right now. That having been said, if you want to suggest any structure changes, go ahead and maybe I can talk to her about it. Thank you!!!
    Attached Files Attached Files

Posting Permissions

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