A Microsoft Office (Excel, Word) forum. OfficeFrustration

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.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

List Box / Forms



 
 
Thread Tools Display Modes
  #1  
Old August 26th, 2004, 04:33 PM
Michelle T
external usenet poster
 
Posts: n/a
Default List Box / Forms

Hi:

I haven't used Access for 2 years so I'm very rusty and
need some assistance.

I'm creating a Contact database and what we would like to
do is the following:

In the switchboard, have a button set up for each letter
of the alphabet. When the user clicks on the letter, a
query will come up that shows all the users that match
that letter. This works fine.

Now I'm trying to create a list box using this query and
when the user clicks on the client, I want another Form I
created to open and show the client's information. I'm
very confused about the VBA codes needed for this to
happen.

Any help would be great!

Thanks,
Michelle


  #2  
Old August 26th, 2004, 05:04 PM
Dan Artuso
external usenet poster
 
Posts: n/a
Default

Hi Michelle,
What you do is first create a form that displays all client's info.
You should have something like a ClientId field in the query.

Now, your listbox should contain the ClientId as well, this should be the 1st column
and the bound column as well. I assume you have the name showing in another column in the listbox.

So now in the click (or DoubleClick) event of the listbox you can simply put:

DoCmd.OpenForm "yourFormName",,,"ClientId = " & Me.yourListbox

Substitute the correct names of course!
If I didn't exlplain that well enough, post back.

HTH
Dan Artuso, MVP



"Michelle T" wrote in message ...
Hi:

I haven't used Access for 2 years so I'm very rusty and
need some assistance.

I'm creating a Contact database and what we would like to
do is the following:

In the switchboard, have a button set up for each letter
of the alphabet. When the user clicks on the letter, a
query will come up that shows all the users that match
that letter. This works fine.

Now I'm trying to create a list box using this query and
when the user clicks on the client, I want another Form I
created to open and show the client's information. I'm
very confused about the VBA codes needed for this to
happen.

Any help would be great!

Thanks,
Michelle




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
validation list trey Worksheet Functions 13 August 15th, 2004 05:32 AM
Drop Down Menus Dude Worksheet Functions 1 June 24th, 2004 12:25 AM
outlook 2003 public folders of custom list Lynda Contacts 1 June 9th, 2004 01:25 PM
List Box Size Orf Bartrop New Users 12 May 29th, 2004 02:10 AM
How to make list of unique values? JulieD Worksheet Functions 1 February 26th, 2004 12:25 PM


All times are GMT +1. The time now is 01:44 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.