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  

Combo Box Problem



 
 
Thread Tools Display Modes
  #1  
Old April 9th, 2010, 03:55 PM posted to microsoft.public.access.forms
pjscott
external usenet poster
 
Posts: 38
Default Combo Box Problem

I'm using sql 2000 and Access 2007.

I have 2 forms. One form to Enter data and the 2nd to Edit the data.

The Edit form is my problem. The Edit form Record Source is a query that
displays all the records.

I have a combo box assoicated with the Name field. The Edit form's Row
Source is the query.

The name combo box when clicked will display the same name for each record
that's enter under that name.

I have tried creating both a single form and a form / subform. I have also
tried using the name table as the combo box record source but this diaplays
all the names even if they don't have a record assoicated with them.

What do I need to do to get the combo box to display a single name even if
there's several records associated with that name.

Thanks for the help,

Paul
  #2  
Old April 9th, 2010, 04:29 PM posted to microsoft.public.access.forms
KARL DEWEY
external usenet poster
 
Posts: 10,767
Default Combo Box Problem

The name combo box when clicked will display the same name for each record
that's enter under that name.
I do not follow as to what your problem is as a combo makes all names
available to select from but dispalys the one selected.
Is it not doing this?

--
Build a little, test a little.


"pjscott" wrote:

I'm using sql 2000 and Access 2007.

I have 2 forms. One form to Enter data and the 2nd to Edit the data.

The Edit form is my problem. The Edit form Record Source is a query that
displays all the records.

I have a combo box assoicated with the Name field. The Edit form's Row
Source is the query.

The name combo box when clicked will display the same name for each record
that's enter under that name.

I have tried creating both a single form and a form / subform. I have also
tried using the name table as the combo box record source but this diaplays
all the names even if they don't have a record assoicated with them.

What do I need to do to get the combo box to display a single name even if
there's several records associated with that name.

Thanks for the help,

Paul

  #3  
Old April 9th, 2010, 04:49 PM posted to microsoft.public.access.forms
pjscott
external usenet poster
 
Posts: 38
Default Combo Box Problem

If there's 3 records with the same name the name displays 3 times in the
combo box.

I need for the name to display single time then I can navigate through the
different records on the form.

Thanks,

Paul

"KARL DEWEY" wrote:

The name combo box when clicked will display the same name for each record

that's enter under that name.
I do not follow as to what your problem is as a combo makes all names
available to select from but dispalys the one selected.
Is it not doing this?

--
Build a little, test a little.


"pjscott" wrote:

I'm using sql 2000 and Access 2007.

I have 2 forms. One form to Enter data and the 2nd to Edit the data.

The Edit form is my problem. The Edit form Record Source is a query that
displays all the records.

I have a combo box assoicated with the Name field. The Edit form's Row
Source is the query.

The name combo box when clicked will display the same name for each record
that's enter under that name.

I have tried creating both a single form and a form / subform. I have also
tried using the name table as the combo box record source but this diaplays
all the names even if they don't have a record assoicated with them.

What do I need to do to get the combo box to display a single name even if
there's several records associated with that name.

Thanks for the help,

Paul

  #4  
Old April 9th, 2010, 06:09 PM posted to microsoft.public.access.forms
Maurice
external usenet poster
 
Posts: 1,585
Default Combo Box Problem

You have based the combobox source on your table. So what you need to do is
create a query based on your table. Next choose the field you would like to
see (Name) and add that to the grid. Now that will show all the names
including the duplicates. To remove the duplicates you have to make the SQL
statement distinct.

When in query design goto the design button (far left). From the arrow
choose SQL you will see the SQL statement. Now after the word Select add the
word Distinct and view the result.

hth
--
Maurice Ausum


"pjscott" wrote:

If there's 3 records with the same name the name displays 3 times in the
combo box.

I need for the name to display single time then I can navigate through the
different records on the form.

Thanks,

Paul

"KARL DEWEY" wrote:

The name combo box when clicked will display the same name for each record

that's enter under that name.
I do not follow as to what your problem is as a combo makes all names
available to select from but dispalys the one selected.
Is it not doing this?

--
Build a little, test a little.


"pjscott" wrote:

I'm using sql 2000 and Access 2007.

I have 2 forms. One form to Enter data and the 2nd to Edit the data.

The Edit form is my problem. The Edit form Record Source is a query that
displays all the records.

I have a combo box assoicated with the Name field. The Edit form's Row
Source is the query.

The name combo box when clicked will display the same name for each record
that's enter under that name.

I have tried creating both a single form and a form / subform. I have also
tried using the name table as the combo box record source but this diaplays
all the names even if they don't have a record assoicated with them.

What do I need to do to get the combo box to display a single name even if
there's several records associated with that name.

Thanks for the help,

Paul

  #5  
Old April 9th, 2010, 06:25 PM posted to microsoft.public.access.forms
John W. Vinson
external usenet poster
 
Posts: 18,261
Default Combo Box Problem

On Fri, 9 Apr 2010 08:49:01 -0700, pjscott
wrote:

If there's 3 records with the same name the name displays 3 times in the
combo box.

I need for the name to display single time then I can navigate through the
different records on the form.


Use a different query than the form's recordsource as the rowsource; in
particular, use a query which retrieves only one instance of each name. This
could be based on the names table, or use a Unique Values query to display
each name only once - not sure how your tables are structured so I can't say
for sure!
--

John W. Vinson [MVP]
  #6  
Old April 9th, 2010, 07:51 PM posted to microsoft.public.access.forms
pjscott
external usenet poster
 
Posts: 38
Default Combo Box Problem

Thanks for the help. It's time for the weekend so I'll give these a try on
Monday.

Hope you have a good weekend,

Paul


"John W. Vinson" wrote:

On Fri, 9 Apr 2010 08:49:01 -0700, pjscott
wrote:

If there's 3 records with the same name the name displays 3 times in the
combo box.

I need for the name to display single time then I can navigate through the
different records on the form.


Use a different query than the form's recordsource as the rowsource; in
particular, use a query which retrieves only one instance of each name. This
could be based on the names table, or use a Unique Values query to display
each name only once - not sure how your tables are structured so I can't say
for sure!
--

John W. Vinson [MVP]
.

 




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


All times are GMT +1. The time now is 05:58 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.