Link to home
Start Free TrialLog in
Avatar of taborrg
taborrg

asked on

Access 2007. Use a list box on one form to open another form and populate it with selected information.

Hi,

I have a list box to select a client.  Then I need it to open another form to display that client's information.

Thanks,

Rick
Avatar of jdc1944
jdc1944
Flag of United Kingdom of Great Britain and Northern Ireland image

basically you need to reference the list box in the query that will display the clients name and then add a button on the form to open the other form with the clients info.

for example if your list box is storing a client ID called ClientID, your form is containing the list box is called frmClients.  then in the query that runs the form that shows the client information you can add [forms]![frmClients]![ClientID] to the criteria of the client ID in the query, if that makes any sense.
ASKER CERTIFIED SOLUTION
Avatar of peter57r
peter57r
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hopefully what you are after is attached in my example database, its a very basic way of doing it.

You can also ignore the button and add an afterupdate event to open the form instead.
Example.mdb
Avatar of taborrg
taborrg

ASKER

I'm sorry, I couldn't follow that.

I have a table named Clients with ClientID and ClientName

A form with listbox lstSelectClient that looks at the Clients table

Another form with fields for client information.

can you upload your database?
whats the name of the other form that you want to open?
Avatar of taborrg

ASKER

Great!  Work right off.

Thanks!
Avatar of taborrg

ASKER

jdc1944 - thanks for the quick response!