Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2003

    Unanswered: Field value based on prior value entered in table:

    For practice I am creating a database for comic books.
    I have created tables to hold Creators names, Publisher names, comic professions, titles, etc...

    I always knew in a form you could create a listbox to display the possible values from a table that held those values.

    BUT, I just discovered that I can do that in the Table....

    However, to make it even more idiot proof, and easy to enter data, I want one fields value options to be based on the value entered in the previous field.
    Example: If I am in Table Data entry view, my fields are in the following order:
    Publisher - Title - Series - Issue - Writer - Penciller - Inker - Etc

    What I want to do is this:
    When you choose the Publisher, then the list box under Title will then only display comic books printed by that specific publisher...

    I know how to set it up so that the listbox looks up all Titles, but there has to be a way to pass the value that is chosen in the Publisher field to the query looking up the possible Title values...


  2. #2
    Join Date
    Feb 2002
    This can be done on a form. Using combo boxes.

    Combobox1 holds information about the Publisher. In the after update event of this combobox you would place some code like:


    Where cbo2 is the combo box carrying the title data. In the query under this combo box you would include a field for the publisher, and the criteria for this field would be based on the form combobox1.

    that is it, the query in combobox2 is restricted by the value in combobox1 and the query is run after the value in box1 is selected.


Posting Permissions

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