If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Combo Boxes-Access 2007
Two tables as follows:
tblSenior Intake tblSenior Intake ID-PK tblFname tblMiddleName tblLastName tblAddress tblCity tblTownship tblState tblPostalCode TblHomePhone etc. tblSchedule tblSchedule ID-PK tblDriver tblDay tblAppointmentTime tblCancelled tblWhoCancelled tblFname tblLastName tblAddress tblCity tblHomePhone tblAppointmentTime tblAppointmentNotes tblDestination tblReturnTime tblReasonforTransportation Want to create a combo box so that end user selects name and the Fname,LastName,Address,City, and HomePhone fields automatically complete in the form. |
#2
|
|||
|
|||
Combo Boxes-Access 2007
Name is not one of your field names and it should not be. Name is a reserved
word in Access. So are you talking about TblFname? It would usually be better to search on the pk but you can probably search on Fname. Create the combo. Allow the wizard to selct fname as your source. Then go into the afterupdate property of the combo and start the code builder. Type: Me.filter = "[tblfname' = """ & Me.combo# & """" Me.filteron = true The combo# will be listed and will be something like combo12 or combo110. -- Milton Purdy ACCESS State of Arkansas "SueW" wrote: Two tables as follows: tblSenior Intake tblSenior Intake ID-PK tblFname tblMiddleName tblLastName tblAddress tblCity tblTownship tblState tblPostalCode TblHomePhone etc. tblSchedule tblSchedule ID-PK tblDriver tblDay tblAppointmentTime tblCancelled tblWhoCancelled tblFname tblLastName tblAddress tblCity tblHomePhone tblAppointmentTime tblAppointmentNotes tblDestination tblReturnTime tblReasonforTransportation Want to create a combo box so that end user selects name and the Fname,LastName,Address,City, and HomePhone fields automatically complete in the form. |
#3
|
|||
|
|||
Combo Boxes-Access 2007
On Tue, 6 Apr 2010 13:34:02 -0700, SueW
wrote: Two tables as follows: tblSenior Intake tblSenior Intake ID-PK tblFname tblMiddleName tblLastName tblAddress tblCity tblTownship tblState tblPostalCode TblHomePhone etc. tblSchedule tblSchedule ID-PK tblDriver tblDay tblAppointmentTime tblCancelled tblWhoCancelled tblFname tblLastName tblAddress tblCity tblHomePhone tblAppointmentTime tblAppointmentNotes tblDestination tblReturnTime tblReasonforTransportation Sorry, but your table design is WRONG. Relational databases use the "Grandmother's Pantry Principle" - "a place - ONE place! - for everything, everything in its place". You should NOT repeat fields (HomePhone, LastName, Address, etc.) redundantly in the schedule table. That information should exist only in the "intake" table; the only field from that table which should be included in the transportation table is the ID, as a foreign key link. You could use a Form based on Intake with a subform based on Transportation in order to see the information from both tables in conjunction. -- John W. Vinson [MVP] |
Thread Tools | |
Display Modes | |
|
|