Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2008
    Posts
    2

    Unanswered: Auto Populating Fields

    First off, I'm a true beginner to Access, I've toyed with it over the years but never to extent that I'm currently attempting. So I have a pretty simple database that contains the following;(btw im using Access 2007)
    a Customers Table, Vendors Table, Jobs Table, and Purchase Orders Table. What I'm trying to create is a report, query or form(or whatever is best)(please advise) that when I select a vendor from my vendors list, it will automatically populate the address, city, state, and zipcode in the form from the vendors table. I'm EXTREMELY grateful for anyone who helps me in advance.

  2. #2
    Join Date
    Dec 2004
    Location
    Madison, WI
    Posts
    3,926
    This is a difficult question to answer with the way you've put it. If it's on a form, there are a few different ways of doing this depending on how your form is set up. Most often, an unbound (search type) combobox is put on the form which shows as a rowsource, the customer name (or vendor name) field in the specified table. Then usually you have code in the afterupdate event of the combobox to return or go to the record selected in the combobox to the form, populating the address and other fields from that record. The Northwind database that comes with Access shows how you can do these type of searches or there are other examples uploaded in our code bank or other places on the web showing how to do searches on records.

    Without more info on exactly what you're trying to do, that's the best I can offer.
    Last edited by pkstormy; 01-25-08 at 23:23.
    Expert Database Programming
    MSAccess since 1.0, SQL Server since 6.5, Visual Basic (5.0, 6.0)

  3. #3
    Join Date
    Jan 2008
    Posts
    2
    pkstormy, thanks for the reply, what information would you need in order to better understand what im trying to achieve?

  4. #4
    Join Date
    Dec 2002
    Location
    Préverenges, Switzerland
    Posts
    3,740
    the table fields
    the table relationships (your Foreign Key fields should make this obvious if they have meaningful names)

    ultimately you will be creating a query - then it's up to you if the result set goes to a report or a form.

    izy
    currently using SS 2008R2

Posting Permissions

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