Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Combo box not displaying all records

0 views
Skip to first unread message

Sean Henry

unread,
Mar 12, 2003, 7:43:26 PM3/12/03
to
I cannot find any support about this on the Knowledge Base. I have an
application that runs fine on my systems, and many others, but 2 or 3
customers are having problems with a few combo boxes.

It will not display all the records. It does on other systems.

It is a basic 2 column combo box, and will have a couple thousand records in
it.

It seems as if it will only display the amount of records that the listrows
value is set to, and you are not able to scroll down any farther.

Sometimes if you use the arrow keys, and your mouse it scrolls down. If you
enter data in manually, it will not.

They are using Acces 2000. I cannot figure it out,a nd installing service
packs didn't seem to help.


Thanks in advance.

Sean Henry


Adrian Jansen

unread,
Mar 13, 2003, 6:25:58 PM3/13/03
to
I have struck intermittent problem like this with combo boxes too.
Sometimes it helps to do a movelast on the recordset the combo box is based
on, to ensure all records are loaded. Sometimes it helps to NOT requery the
combo box after changing its recordsource - ie doing a requery seems to make
the problem worse !

Never found a really good fix, except limiting the records in a combo box to
less than 1000 or so with some form of external filter - eg another combo
box to set some sort of grouping of the records.

--
Regards,

Adrian Jansen
J & K MicroSystems
Microcomputer solutions for industrial control
"Sean Henry" <ne...@mastersolutions.com> wrote in message
news:ejnRufP6...@TK2MSFTNGP10.phx.gbl...

Sean Henry

unread,
Mar 13, 2003, 9:46:30 PM3/13/03
to
Interesting. I am certain it has to do with memory, and allocating
resou8rces. I also bet it has something to do with dll files, and
realtionships with Os's.

I requery this box all the time, as it can change. I bet that is a key. I
will be able to test it tomorrow.

This may sound like a dumb question, but I always use queries as sources for
combo boxes. How do I apply a recordset to a combo box? That would probably
be a good way for me because of the nature of the data, and the way it
handles.

Sean Henry

"Adrian Jansen" <q...@noqqwhere.com> wrote in message
news:bN8ca.44$Jh2...@newsfeeds.bigpond.com...

Adrian Jansen

unread,
Mar 14, 2003, 2:39:06 AM3/14/03
to
Yes, I suspect memory ( or its allocation ) too. The problem seemed much
worse on a Win95 machine runninng A97 with only 48 Mb of RAM. Havent
actually noticed it on a Win2000 machine running A2002 with 512 Mb. But the
fact that it occurs at all without any warning can be really annoying.

The query is a recordset, so you can do things in code like:

dim rs as DAO.Recordset

set rs = currentdb.OpenRecordset("yourqueryname")

rs.movelast 'to fully load the recordset

me.yourcombobox.recordsource = rs

that should do it. Remember to do
rs.close
set rs = nothing

on closing the form, or you WILL eat some memory


--
Regards,

Adrian Jansen
J & K MicroSystems
Microcomputer solutions for industrial control
"Sean Henry" <ne...@mastersolutions.com> wrote in message

news:#rsPOJd6...@TK2MSFTNGP12.phx.gbl...

Sean Henry

unread,
Mar 14, 2003, 10:13:43 AM3/14/03
to
Thank you so much. The machines in question right now are win98 with Acces
2000. Believe it or not they are running 8 workstations peer to peer!

The only other time I saw this was on some machines running Win XP with
Acces 97 (!). I sure hope I can fix it. Thanks for the tip.

Sean

"Adrian Jansen" <q...@noqqwhere.com> wrote in message

news:sDfca.176$dE2...@newsfeeds.bigpond.com...

Sean Henry

unread,
Mar 14, 2003, 10:31:59 AM3/14/03
to
I take it back. There is no recordsource mthod or object for my combo box.
It doesn't work. Am I missing something? Here is my code:

Dim frm As Form
Dim ctl As Control
Dim rst As DAO.Recordset
Dim str As String

Set frm = Forms("Preferences_f")
Set ctl = frm.Controls("LimitPOPartsToCrossRef")

Select Case ctl.Value
Case True
Set rst =
CurrentDb.OpenRecordset("FQ_PurchaseOrderDetails_sf_PartNumCrossRef")
Case False
Set rst =
CurrentDb.OpenRecordset("FQ_PurchaseOrderDetails_sf_PartNum_q")
End Select

rst.MoveLast
Me.InternalPartNum.RecordSource = rst

There is also this method which doesn't work either

Me.InternalPartNum.RowSource = rst

Sean

"Adrian Jansen" <q...@noqqwhere.com> wrote in message

news:sDfca.176$dE2...@newsfeeds.bigpond.com...

Adrian Jansen

unread,
Mar 14, 2003, 7:48:19 PM3/14/03
to
Assuming your combo box is called InternalPartNum
The statement

Me.InternalPartNum.RowSource = rst

sets the rowsource to a recordset. But I think the rowsource for a combo
box is expecting a string, like an SQL statement. Perhaps try

Me.InternalPartNum.RowSource = rst.name

Sean Henry

unread,
Mar 15, 2003, 9:23:09 AM3/15/03
to
Me.InternalPartNum.RowSource = rst gives me an error. I will try the
other. I think the situation is fixed, as I removed all the dropdown and
requerying code. It is a drag, but better than it not working!!

Sean


"Adrian Jansen" <q...@noqqwhere.com> wrote in message

news:JRuca.646$dE2....@newsfeeds.bigpond.com...

0 new messages