Drop down list in Form in Access

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rgsw
    New Member
    • Jul 2006
    • 29

    Drop down list in Form in Access

    I would like to create a drop down list in a form. When month is selected I would like information for that month only to show in form. Would I have to connect to a different table for each month? How would this drop down list be created in form? Usually I have transferred information to an excel spreadsheet then delete entries and start over in next month. But I would like all months entries to be in the database without transferring to excel. Thanks!
  • comteck
    New Member
    • Jun 2006
    • 179

    #2
    You create a table containing all the items that are to appear in your drop down list. Then you add a combo box to your form, and in Row Source property of the combo box, type the following:

    SELECT DISTINCTROW [tblName].[fieldName] FROM [tblName];

    If you want more than one field to appear, then separate them by a comma.

    Hope this helps.
    comteck

    Comment

    • rgsw
      New Member
      • Jul 2006
      • 29

      #3
      Thanks for your help! However, I must be missing something (first time using combo box) after trying your suggestion, when I select the field only the first first shows up. How do I have all fields show that I have selected? :confused:

      Comment

      • comteck
        New Member
        • Jun 2006
        • 179

        #4
        The fields are taken from the table. Either the SELECT statement is wrong, or the data is missing from the table.

        If neither of these doesn't work, the easiest way might be to delete the combo box and create it again.

        comteck

        Comment

        Working...