Results 1 to 3 of 3
  1. #1
    pfunk is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2012
    Posts
    9

    Auto Populate from combobox but save in new table

    What I am trying to do is select a book from the comb box and have the other information auto-populate. That being said I also want it to save in the feedback table. I know this is duplicating data but it is what I need for stat purposes and exporting to excel later. I have attached photos to show the books table
    Click image for larger version. 

Name:	books table.jpg 
Views:	8 
Size:	97.4 KB 
ID:	8909
    the feedback form
    Click image for larger version. 

Name:	feedback form.jpg 
Views:	7 
Size:	103.5 KB 
ID:	8910
    and the feedback table


    Click image for larger version. 

Name:	feedback table.jpg 
Views:	7 
Size:	94.7 KB 
ID:	8911

  2. #2
    pfunk is offline Novice
    Windows Vista Access 2007
    Join Date
    Aug 2012
    Posts
    9
    I got it to work with a dlookup function!

  3. #3
    Missinglinq's Avatar
    Missinglinq is offline VIP
    Windows 7 64bit Access 2007
    Join Date
    May 2012
    Location
    Richmond (Virginia, not North Yorkshire!)
    Posts
    3,018
    That's one method. The other would be to include the info in the Combobox and then assign it in the AfterUpdate event. To do this you'd simply

    Set up your Combobox using the Wizard and include the Fields you need, from Left-to-Right.

    If in the Combobox they appear as

    Field1 | Field2 | Field3

    the code would be

    Code:
    Private Sub YourComboBox_AfterUpdate()
       Me.txtField1 =  Me.YourComboBox.Column(0)
       Me.txtField2 = Me.YourComboBox.Column(1)
       Me.txtField3= Me.YourComboBox.Column(2)
    End Sub

    Notice that the column index is Zero-based.

    Linq ;0)>
    The problem with making anything foolproof...is that fools are so darn ingenious!

    All posts/responses based on Access 2003/2007

Please reply to this thread with any new information or opinions.

Similar Threads

  1. How to populate combobox via VBA
    By chuki2 in forum Programming
    Replies: 7
    Last Post: 08-15-2012, 10:42 AM
  2. Auto-populate from another table
    By Palladian1881 in forum Access
    Replies: 2
    Last Post: 08-16-2011, 11:29 AM
  3. Replies: 4
    Last Post: 08-15-2011, 10:06 AM
  4. Save Combobox results to Table
    By Kinder0177 in forum Access
    Replies: 5
    Last Post: 06-29-2011, 08:47 AM
  5. auto populate and table relationships
    By jmarti57 in forum Access
    Replies: 0
    Last Post: 11-09-2008, 09:50 PM

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
  •  
Other Forums: Microsoft Office Forums