really starting to dislike Access

  • Thread starter Thread starter brandon8201
  • Start date Start date
B

brandon8201

Guest
I've already posted 3 threads on here for help and all the help I have recieved seems very logical...for the people submitting...I do appreciate the help, don't get me wrong. I am still having troubles getting my combo boxes to work correctly. When I select the 'Make' then I want to be able to select only the models available for that certain make, it doesn't work. If anyone can give further help, I would really appreciate it! Thanks, brandon
 
Brandon

Would you like some samples of this? If you tell me which version of access you are using I can send them to you. It took me a while to grasp this but the samples really helped me to understand how it worked.

hayley.baxter@bskyb.com (daytime email)

or

HaylBaxter@aol.com

Hayley
 
Brandon

I've sent you two samples let me know if you don't get them and I will resend.

HTH
Hay
 
Hi

If you search for cascading comboboxes you'll find an example that you can download - kindly posted by DBL - thanks Dawn

Col
 
Hi

How are your tables set up? I presume you have a 'make' table and a 'model' table, and you have an ID number for each make and model.

tblMake tblModel

'Make' MakeID 'Model' ModelID
Ford 1 Galaxy 1
Citroen 2 AX 2
KA 3

So you have unique reference numbers for each make and model. For instance Ford make both the Galaxy and Ka models, so you have a table linking the ID numbers together.

tblLinkMakeModel

MakeID ModelID
1 1
1 3

Then create a query qryJoinMakeModel, and add the above tables to it and choose the fields you wnat (make, model, ModelID, MakeID).
In your second combo box (if the first combo is make) you look for model. In the RowSource (under 'properties') add a sql statement which makes your second combo only look for the relevant model. Ie.
SELECT qryJoinJoinMakeModel.Make, qryJoinJoinMakeModel.Model, qryJoinJoinMakeModel.MakeID, qryJoinJoinMakeModel.ModelID FROM qryJoinJoinMakeModel WHERE (((qryJoinJoinMakeModel.Make)=[forms]![frmWhatever]![cmboMake])) ORDER BY qryJoinJoinMakeModel.Model;
Just replace the table, query and field names with your own.
I hope this makes sense, and is what you wanted (and that my SQL is correct!!!), if not, post back. :)
 
Hello Brandon

I've sent your database back to you. Your combo boxes now appear to be working. If you have any more problems or you want to pull the data on the second combo just let me know - I expect that after you select from combo 1 and combo 2 you will want to pull up the vehicle information. I'll keep a copy of the database and just give me a shout if anything else comes up.

I hope this helps and is what you are looking for.

Hayley
 

Users who are viewing this thread

Back
Top Bottom