• Combobox not showing all records (Access2000)

    Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Combobox not showing all records (Access2000)

    Author
    Topic
    #409066

    I’ve got a weird problem. In a new application for an existing client, I have a combo box that sometimes doesn’t show all records! It is weird because sometimes it does show all records. When it happens it seems to affect all users, and when it works it works for everyone! This is not a huge recordset either, maybe 750 records should be returned from a table that holds maybe 15,000 records.

    I’m suspecting a timing problem within Access, perhaps caused by some problem with the network. I discussed it with the hardware guy, and we are going to replace their current hub with a switch, and to relocate the server closer to the switch. The server is a Linux box. Even if this isn’t the cause of the current problem, we think these steps are prudent anyways.

    Anyone have any thoughts on any other situations that might be causing this problem?

    Viewing 3 reply threads
    Author
    Replies
    • #869081

      I’ve run into similar problems with combo boxes but ususally it returns all the records or no records at all. I’ve had some success changing the combo boxes row source from a SQL statement to a saved query or visa versa depending on how it was set-up originally. I’ve also had to change the row source from a table to a query that brings back all records Select “*”. I never could get to the bottom of it but I’ve usually worked around it by varying the row source as illustrated.
      Hope that helps.

      • #869085

        My rowsource is already a SQL statement, although not a saved query. But even so, what bothers me is the inconsistent behaviour; sometimes it works properly, sometimes it doesn’t.

        • #869123

          That’s what bugged me as well and I could never figure it out. Try changing the SQL to a saved query. Who knows if it will work but it’s worth a shot (if it does work, it still doesn’t explain the inconsistent results)

        • #869124

          That’s what bugged me as well and I could never figure it out. Try changing the SQL to a saved query. Who knows if it will work but it’s worth a shot (if it does work, it still doesn’t explain the inconsistent results)

      • #869086

        My rowsource is already a SQL statement, although not a saved query. But even so, what bothers me is the inconsistent behaviour; sometimes it works properly, sometimes it doesn’t.

    • #869082

      I’ve run into similar problems with combo boxes but ususally it returns all the records or no records at all. I’ve had some success changing the combo boxes row source from a SQL statement to a saved query or visa versa depending on how it was set-up originally. I’ve also had to change the row source from a table to a query that brings back all records Select “*”. I never could get to the bottom of it but I’ve usually worked around it by varying the row source as illustrated.
      Hope that helps.

    • #869099

      Could you post the SQL that the combobox is using?

      Also, do you know how many records should be displayed, ie, should it always return 750 records, or is it a bit more flexible then that?

      • #869186

        I know it is not the SQL statement. The combo box is returning a list of clients in order by state. Those times when it is not acting properly, it doesn’t return anything beyond “CA”.

        I know that Access doesn’t fill all of a combobox until it needs it. So with really big recordsets you often can move the scrollbar down, forcing Access to read more records. In this situation it is really a relatively small recordset, and you can move the scrollbar all the way down, and no more records are being read.

        • #869193

          That’s not entirely true. A combobox has to get the initial ‘count’ when it loads, so when the list is dropped down, the data my not be ‘all there’, but the slider will be the appropriate size. You may want to look into using a callback function, if you suspect you are ‘losing’ the connection somehow.

          • #869201

            That’s not the consistent with what I’ve seen. If you have a really big recordset, you can move the slider all the way to the bottom, but when you release it it will “bounce up” to reflect its new position in the recordset, allowing you to slide it down even further. Depending on the size of the recordset, you can repeat this action many times.

            • #869205

              Hmm, you’re right, I guess I deal with Callback functions too much, because with a callback function, it DOES size the slider based on the number of items. Try populating the combo with a callback function.

            • #869206

              Hmm, you’re right, I guess I deal with Callback functions too much, because with a callback function, it DOES size the slider based on the number of items. Try populating the combo with a callback function.

          • #869202

            That’s not the consistent with what I’ve seen. If you have a really big recordset, you can move the slider all the way to the bottom, but when you release it it will “bounce up” to reflect its new position in the recordset, allowing you to slide it down even further. Depending on the size of the recordset, you can repeat this action many times.

          • #869203

            If a combo box has a large number of items, the scrollbar thumb will have its minimum size, but you can infer that the exact number of items is not known yet, for if you drag the thumb all the way down, it will not take you to the last item, and it will jump back part of the way when you release it. Depending on the number of list items, you can repeat this one or more times. Only when you have reached the last record will the thumb act correctly.

          • #869204

            If a combo box has a large number of items, the scrollbar thumb will have its minimum size, but you can infer that the exact number of items is not known yet, for if you drag the thumb all the way down, it will not take you to the last item, and it will jump back part of the way when you release it. Depending on the number of list items, you can repeat this one or more times. Only when you have reached the last record will the thumb act correctly.

        • #869194

          That’s not entirely true. A combobox has to get the initial ‘count’ when it loads, so when the list is dropped down, the data my not be ‘all there’, but the slider will be the appropriate size. You may want to look into using a callback function, if you suspect you are ‘losing’ the connection somehow.

      • #869187

        I know it is not the SQL statement. The combo box is returning a list of clients in order by state. Those times when it is not acting properly, it doesn’t return anything beyond “CA”.

        I know that Access doesn’t fill all of a combobox until it needs it. So with really big recordsets you often can move the scrollbar down, forcing Access to read more records. In this situation it is really a relatively small recordset, and you can move the scrollbar all the way down, and no more records are being read.

    • #869100

      Could you post the SQL that the combobox is using?

      Also, do you know how many records should be displayed, ie, should it always return 750 records, or is it a bit more flexible then that?

    Viewing 3 reply threads
    Reply To: Combobox not showing all records (Access2000)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: