Link to home
Start Free TrialLog in
Avatar of TownTalk
TownTalkFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Combo Box won't autoexpand

Access 2007. This had been working fine until yesterday. Because of a completely unrelated problem, I imported all my database objects into a new .ACCDB file

Since then, a combo box on one of my unbound forms won't Auto Expand. If I type in an exact value which is present in the list, instead of accepting it, access pops up a message saying "The text you entered isn't an item in the list." But the item is there in the list. The list is derived from a local table. I pruned that table so it only contained a dozen records. This didn't fix the problem

I read somewhere that autocorrect  can cause this. I turned Autocorrect off without success.

Help please.

edit: I just created the same combo box on a brand new form and the combo box works perfectly.

Another Edit: It turns out that the combo box on the new form only works until I quit the database. When I reopen the database, it behaves just like the original one.

Yet another edit: I imported my table into a new database and got exactly the same behaviour there..... A combo box with it's list derved from a local table will only autoexpand when it has just been created. After that, it will not autoexpand
Avatar of als315
als315
Flag of Russian Federation image

May be you can send us an example of db with this problem? If it will work - may be you will need to repar access. Can you test it on other computers?
Avatar of TownTalk

ASKER

Ok here's a sample database. It contains a single table, and a single form containing a combo box. Immediately after I created the form, the combo-box would autoexpand. But afterwards it would not. I've tried this sample database on another machine running Access 2010 and got the same behaviour.

Autoexpand.zip
I have same behaviour with your DB. When I've imported all in a new DB, all seems to be without changes, but, when i've saved form, closed DB and opened it again - all is working.
Test it. If included sample will not work after reopening - problem is in Access, if no - may be it was some DB corruption.
Autoexpand1.zip
Thanks for sending that back. It AutoExpands for me now. So i'm not sure what to make of it....

This was a brand new empty database. So it's dificult to imagine how it could be a curruption problem. I repaired and compacted my original sample and it still exhibits the problem. I repaired and compacted yours, and it is still ok.

I'll re-install access and see if that cures anything......
I've repaired MS Access and i've still got the same problem. grrrr!!
I have not seen any visible problems with your DB. It is likely to some error in your Access. Have you all updates installed?
What do you make of this?.......

I had the idea of taking the sample database which you posted back in here, and importing all the objects from my application into it. It now works absoultely fine.

So it would appear that my problem is in the initial database creation. After all, this problem occured when I imported all the objects into a new database.
Try to create new form with such field and check it. May be problem is in form creation module of Access.
I created a new form in the database you sent back to me. The combo box works fine always. I did exactly the same in the database I sent to you. As usual, it only works during that access session.
When I create a new blank database, does Access create that file from scratch?..... or does it take a copy of a template file that is stored somewhere?..... If the latter is true, I wonder if that template file is corrupted.
ASKER CERTIFIED SOLUTION
Avatar of als315
als315
Flag of Russian Federation 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
Very strange indeed.
I took the original db, opened the Form ... same result.
I added an 2nd combo and configured it the same as the first. Reopend the Form, and BOTH combos worked !!
Then closed the Form w/o saving changes, reopened with just original combo ... it continues to work!

 ....... mx
TownTalk,

I have seen lots of strange things like this  in Access 2007 before SP2.

Do you have the Office 2007 SP2 update installed?
I should note ... I am testing in A2010, so service pak probably not the issue.

mx
mx,

I have seen things work better with 2010 than in 2007/SP1/SP2.  II do think Access 2010 fixes some issue that exist even in  2007 SP2.  Just like Access 2002/2003 was much better than Access 2000 with the same database.

In my testing, Access 2010 is a lot better that Access 2007 before any pf the SP's.  


Yes, you do have a point.  
This is VERY odd.

I just changed a couple of random properties of the combo .. and it starts working !!

Trying to see a pattern ...

mx
Don't be fooled into thinking you got that combo box working.... I found already that I can make it work during the current session, but once you close Access and re-open it, it's misbehaving again.

I'm at home now. So i've no access to that pc.  I'm not sure which Service Pack of Access i'm running. It's whatever is on the installation CD from about 18 months ago.

I'm not in the office now until Friday. I'll check the Service Pack status and maybe re-install.

Thanks for your help so far.
More bizarre:
Unzipped again. Open db. Open Form ... issue is there. Close form.
Create Form2 with one combo ... just dragged a combo box onto Form, then saved as Form1.

Opened original Form ... Issue is GONE !!

Another scenario:
Unzipped ... open db.  Immediately create 2nd Form with one comb0 ... nothing added to combo (row source). Save as Form1.  Open AutoExpandProblem form ... NO issue. It works.

mx
"Don't be fooled into thinking you got that combo box working.... "
Oh, don't worry :-)
I can see it's not working.  
 
Just for the record.  I created a brand new ACCDB,  a new table with a few items,   and a new Form with a combo with items from the table.  The issue does *not* occur in this db.

mx
Has anyone checked the references from one to the other?

I have found, on rare occasion, that if you have (or are missing) references to things like the Office Common Suite, etc. controls can work differently.
I did look at References earlier when I tested in A2010 ... just the standard stuff, ie nothing missing.

mx
Here's a twist:
I have A2007 & A2010 installed on the same machine.
Opened your DB in A2007 and problem exists.
Created new DB and imported all objects, C&R, and the new DB works fine.

I then repeated that process using A2010 and the new DB inherited the problem.

FWIW: I have seen this issue before.
Once in an old DB built in A2002, worked fine until I opened it in A2007 and added a new form with a combo.
The the new form (& combo) behaved like this.
I then imported everything into a new DB and problem went away.
At the time I put this down to corruption and moved on.
Now I'm beginning to wonder.

Cheers
JC
Interestingly, a combo on the same form with a rowsourcetype=ValueList does NOT exhibit the same problem...

JC
I'm back in the office today. Yes I have got Service Pack 2 installed. So i'm going to completely remove and reinstall. Another wierd problem has appeared....

Some of my reports display .bmp logo in a picture control. The logo stopped printing. In design view, the logo will not appeared. I changed it to a .JPG file and all is well. So i'm puzzled about this too.

I'll report back shortly...

Ian
I've reinstalled Access 2007 and service pack 2. The combo box problem does not occur now. I still have the problem with displaying .bmp's and .wmf's in Picture controls. I'll post a seperate question about that if i dont resolve it quickly.

Thanks for your input guys.

Ian