Cascading Combo Box

  • Thread starter dhoover via AccessMonster.com
  • Start date
D

dhoover via AccessMonster.com

I have two tables in my database: Customers and Contracts. The Contracts
table is linked back to the Customer table using CustomerID. Each customer
could have more than one contract so a customer may be listed multiple times
in the Contracts table.

I need a form in which I can select a customer name from a combo box (I need
the customer name to only appear once) and then be able to select from a list
of Contract Numbers that correspond with that particular Customer from a
second combo box and then prefill the rest of the form with the information
pertaining to the selected contract.

What is the best way to do this? I am not a programmer, I have already
looked up cascading combo boxes and the explanations are too complicated
 
K

Klatuu

To make it work, you will have to use the Cascading Combo code. There really
is no other way.
 
D

dhoover via AccessMonster.com

Thanks, can you supply the code, again I'm not a programmer and the code I've
looked at it quite complicated
To make it work, you will have to use the Cascading Combo code. There really
is no other way.
I have two tables in my database: Customers and Contracts. The Contracts
table is linked back to the Customer table using CustomerID. Each customer
[quoted text clipped - 9 lines]
What is the best way to do this? I am not a programmer, I have already
looked up cascading combo boxes and the explanations are too complicated
 
K

Klatuu

I don't know enough about the names of your tables, the fields your are
using, the control names on the form, or how you want to filter it.

Normally, when I write code for others, there is a fee.
That is not a solicitation, as they are not allowed here, just a statment of
fact.
--
Dave Hargis, Microsoft Access MVP


dhoover via AccessMonster.com said:
Thanks, can you supply the code, again I'm not a programmer and the code I've
looked at it quite complicated
To make it work, you will have to use the Cascading Combo code. There really
is no other way.
I have two tables in my database: Customers and Contracts. The Contracts
table is linked back to the Customer table using CustomerID. Each customer
[quoted text clipped - 9 lines]
What is the best way to do this? I am not a programmer, I have already
looked up cascading combo boxes and the explanations are too complicated
 
D

dhoover via AccessMonster.com

Doesn't really help, I know how to set up combo boxes, I need help with
filtering one from the other. Oh well, I figure something out
See whether
http://office.microsoft.com/en-ca/access/HA011730581033.aspx?pid=CH063650361033
helps
I have two tables in my database: Customers and Contracts. The Contracts
table is linked back to the Customer table using CustomerID. Each
[quoted text clipped - 14 lines]
What is the best way to do this? I am not a programmer, I have already
looked up cascading combo boxes and the explanations are too complicated
 
D

dhoover via AccessMonster.com

Doesn't really help, I know how to set up combo boxes, I need help with
filtering one from the other. Oh well, I figure something out
See whether
http://office.microsoft.com/en-ca/access/HA011730581033.aspx?pid=CH063650361033
helps
I have two tables in my database: Customers and Contracts. The Contracts
table is linked back to the Customer table using CustomerID. Each
[quoted text clipped - 14 lines]
What is the best way to do this? I am not a programmer, I have already
looked up cascading combo boxes and the explanations are too complicated
 
D

dhoover via AccessMonster.com

Doesn't really help, I know how to set up combo boxes, I need help with
filtering one from the other. Oh well, I figure something out
See whether
http://office.microsoft.com/en-ca/access/HA011730581033.aspx?pid=CH063650361033
helps
I have two tables in my database: Customers and Contracts. The Contracts
table is linked back to the Customer table using CustomerID. Each
[quoted text clipped - 14 lines]
What is the best way to do this? I am not a programmer, I have already
looked up cascading combo boxes and the explanations are too complicated
 
D

Douglas J. Steele

That's exactly what that article shows!

From the page cited:

"Making choices is what a combo box is for, but sometimes one choice depends
on another. In this article, you'll learn how to set up one combo box so
that its list is based on the selection you make in another. We provide an
example in a sample database that you can download."

and

"Question: How do I create a combo box that limits its list based on the
selection made in another combo box?

You base the second combo box on a query that matches rows containing the
value selected in the first combo box. You'll also need to place some
Microsoft Visual Basic for Applications (VBA) code in certain form and
control events. The code makes sure that the combo boxes display the right
values when certain things happen - such as when you make a choice in the
first combo box, or when you first open the form."

--
Doug Steele, Microsoft Access MVP

(no e-mails, please!)


dhoover via AccessMonster.com said:
Doesn't really help, I know how to set up combo boxes, I need help with
filtering one from the other. Oh well, I figure something out
See whether
http://office.microsoft.com/en-ca/access/HA011730581033.aspx?pid=CH063650361033
helps
I have two tables in my database: Customers and Contracts. The Contracts
table is linked back to the Customer table using CustomerID. Each
[quoted text clipped - 14 lines]
What is the best way to do this? I am not a programmer, I have already
looked up cascading combo boxes and the explanations are too complicated
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top