Link to home
Start Free TrialLog in
Avatar of Adam Howe
Adam HoweFlag for Australia

asked on

Has anyone encountered issues with an Access 2010 Combo Box not functioning correctly?

I have a Bound Combo Box on a Main Form that has it’s Row Source set to a Union Query.

The Bound Column is set to 1. (Primary Key)

The Column Count is set to 4.

The Column Widths are set to 0cm; 5cm; 0cm; 0cm

When I open the Form the Combo Box is completely empty (ie no row data is displayed) even though I know the field it is bound to has a valid Primary Key value assigned.

When I Open the underlying Union Query that shows the correct row data, so I know there isn’t an error there.
The weird thing is that when I go back into design view and change the Column Widths to 1cm; 5cm; 0cm; 0cm then open the Form the Combo Box functions correctly, apart from the fact that it displays the 1st column, the Primary Key value instead of the 2nd column the Description.

I have also created a new blank Form, and inserted the same Combo Box onto it with the Column Widths set to 0cm; 5cm; 0cm; 0cm.  In this case the Combo Box functions correctly.

Is it possible that my Main Form has become corrupted in some way that’s why the combo box isn’t displaying properly?

Has anyone else encountered this before?

Is there a way to fix it?

My Main Form has a quite complex design which I would like to avoid having to rebuild!

Any feedback would be appreciated.
ASKER CERTIFIED SOLUTION
Avatar of Dale Fye
Dale Fye
Flag of United States of America 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
My Main Form has a quite complex design which I would like to avoid having to rebuild!
Then be pro-active
Create a new form
Copy all the objects off the old form
Copy all the code from the old form
Paste into the new form and new form's module
Set the new form's background and tiling (not much else needs that kind of treatment, I think.

Test

if the problem went to the new form, then you have something REALLY weird going on.
If not you are done after renaming the new form

1cm; 5cm; 0cm; 0cm
Why?  Why pull columns and not display them.
The PK, that makes sense.
The other two, not so much

Highly complex forms get brittle
Learn the signs and what you need to rebuild them when you need to.
Backups.
Previous versions working on the drive where the file resides
Corrupted objects are no fun.

NEVER CHANGE THE DESIGN OF AN OBJECT CREATED WITH A2007+ WITH A2003-
Corruption occurs in short order.
Avatar of Adam Howe

ASKER

Thanks Dale and Nick67 for your responses.
After trying a few options, and going back through some back-ups it seems the only solution was to as Dale suggested and create a new database and recreate the corrupt form, from scratch.