Hello all. I am not sure if this is a forms question or a queries question. Probably a bit of both. I saw this idea in a book but can't take it from a simple example to my more complex example. And I have been at it for a long while. :banghead:
access 2007 is my version, btw, a very beginner at Access and vba
So I have Agents, I have Clients, and the Agents sell Insurance Policies to clients. The agents would like to be able to get a list of their clients--all clients--(addresses and policies they now have) and/or also get this list and narrow it by County the Client lives in.
So I wanted to have two combo boxes. One selects the agent, the other selects the county and this would change a list box that I have based on a query that shows all the needed info.
As I said, I saw this in a book and looked like a great idea but I am in WAAAY over my head on the query and joins especially with the number of "lookup" tables I have and the junction tables to.
I did manage to create a query that when run by itself, it actually displays all the records and all the required fields. Now I just need to figure out how to get this to change based on combo box selections.
I am not sure what question to ask here or where to start. I think my query may actually be wrong for what I need--but right for a stand alone query. I know i need the row source of the list box to change based on an after update event to the combo boxes, but that is where I am lost. I created my query in query design view and have no idea how or what to change in vba.
Any chance someone might know of a simpler way to get where I am trying to go? Or a good tutorial? Or maybe can ask me some questions that I might be able to give enough information to get some help?
Anything would be greatly appreciated.
access 2007 is my version, btw, a very beginner at Access and vba
So I have Agents, I have Clients, and the Agents sell Insurance Policies to clients. The agents would like to be able to get a list of their clients--all clients--(addresses and policies they now have) and/or also get this list and narrow it by County the Client lives in.
So I wanted to have two combo boxes. One selects the agent, the other selects the county and this would change a list box that I have based on a query that shows all the needed info.
As I said, I saw this in a book and looked like a great idea but I am in WAAAY over my head on the query and joins especially with the number of "lookup" tables I have and the junction tables to.
I did manage to create a query that when run by itself, it actually displays all the records and all the required fields. Now I just need to figure out how to get this to change based on combo box selections.
I am not sure what question to ask here or where to start. I think my query may actually be wrong for what I need--but right for a stand alone query. I know i need the row source of the list box to change based on an after update event to the combo boxes, but that is where I am lost. I created my query in query design view and have no idea how or what to change in vba.
Any chance someone might know of a simpler way to get where I am trying to go? Or a good tutorial? Or maybe can ask me some questions that I might be able to give enough information to get some help?
Anything would be greatly appreciated.