Results 1 to 5 of 5
  1. #1
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581

    Training Database

    I'm building a training database for my work. The main tables I have are: Classes Table, Schedule Table, and the Roster Table, and Names Table. The Classes Table have a list of all the classes offered. When a class needs to be scheduled, it is put into the Schedule Table. The Roster Table is to make the actual table and holds the scores. I want to be able to choose students from the Names Table and populate the Roster Table. I was hoping for ideas on how to do this. Right now, I'm blank.

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,550
    Take a form,have a list box on the left of all names, tNames table. (LstNames)
    make a combo box of the classes, so user can pick a class. CboClass.
    a list box on the right to show the names on the class of the cboBox.(lstRoster)

    make a select query runs and shows in the lstRoster looking at the cboClass
    when user picks the class combo, update the lstRoster from the cboClass AFTERUPDATE event.
    Code:
    sub cboClass_afterupdate()
      LstRoster.requery
    end sub
    now add to this list by dbl-clicking on a name in the lstNames. This fires an append query using the items on the form.
    docmd.openquery "qaAdd1name2Roster"

    this query looks like:
    insert into tRoster (studentID, ClassID) values (forms!myForm!lstName, forms!myForm!cboClass)

  3. #3
    orange's Avatar
    orange is offline Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870

  4. #4
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581
    ranman256,
    I have been sidetracked for a while. It looks like that's exactly what I'm trying to do. I'm still a novice at this. I didn't quite get this, "a list box on the right to show the names on the class of the cboBox.(lstRoster)" The first 2 items were simple. I'm not understanding this list box. Do I make another table for it?

  5. #5
    Join Date
    Jun 2015
    Location
    Wales. Land of the sheep.
    Posts
    1,228
    If you put a listbox on a form in design view you can follow the wizard to find the records you wish to show.

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

Similar Threads

  1. Training Database Bug - Please help!
    By Khermann in forum Misc
    Replies: 3
    Last Post: 06-23-2016, 10:32 AM
  2. Employee Training Database
    By hikerdood in forum Database Design
    Replies: 13
    Last Post: 04-19-2016, 05:46 AM
  3. Replies: 1
    Last Post: 06-18-2014, 12:19 AM
  4. How to Create a Training Database
    By jmansfield in forum Access
    Replies: 3
    Last Post: 02-03-2014, 02:56 PM
  5. Training Database
    By BISCUITPUMPER in forum Access
    Replies: 11
    Last Post: 08-20-2011, 10:15 AM

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