Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Access ComboBox Data Issue

Status
Not open for further replies.

earljgray

IS-IT--Management
May 22, 2002
49
US
I have a combobox, unbound, which was created using the combobox Wizard. At the time, the table (Salary results) on which the combox is based held two columns: ID and DATA. The ID column was removed and the RowSource property changed from
SELECT [Salary results].[ID], [Salary results].[DATA]
FROM [Salary results]
ORDER BY [Salary results].[DATA];

to

SELECT [Salary results].[DATA]
FROM [Salary results]
ORDER BY [Salary results].[DATA];

and saved. When in FORM view, clicking on the combobox brings up a paramter box - [Salary results].[ID]:

and the rowsource has been changed to:
SELECT [Salary results].[ID] AS Expr1, [Salary results].[DATA]FROM [Salary results]ORDER BY [Salary results].[DATA];

I can't get Access to stop creating a
[Salary results].[ID] AS Expr1
even though there is no ID any longer and the rowsource was specifically designed to reflect the change.

What am I missing?

Thanks to all
 
Why not simply delete and the recreate the combo ?

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
If I have to... there are over 40 combo boxes that could be corrected more easily (they're all tied to a VBA set of modules to save / display info....


Crystal Reports Design/training/Consultation
ecsdata@ecsdata.com
 
Is there any code that sets the rowsource of this combo.
 
No... the rowsource is set in properties. There are 5 distinct tables that are being used for lookup. They were initially set up

ID DATA

and that was the table that existed when the Wizard was used.

The ID column was removed leaving only 1 column - DATA

Since then ther RowSource property wants to insert ID as an Expression... it's as if there is a pointer to the original (2 column) definition of the control that overwrites any changes....

I've changed the rowsource to look at the table (since it only has one field anyway) and the combobox comes up empty on dropdown...

Frustrating! Like working with a black box. If there were only a couple of controls - no problem - but this for is dense with combo boxes.....

But .... if necessary ... I'll replace them all...


Crystal Reports Design/training/Consultation
ecsdata@ecsdata.com
 
Almost sounds like corruption. However, check all the "Filter" and "Order By" properties. Maybe if ID is included there it somehow forces it back.

Can you explain about a form with 40 comboboxes? I have built some pretty complicated databases, but if I gave a user a form with 40 combos I would expect to get shot in the head. Maybe there is a better way.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top