I am perplexed by an issue with a listbox on a tab control. Here's some background: the tab control has three tabs and all of them have a listbox on them. In the Form_Load event, I run functions that update each of the listboxes. The first two load fine, but the third one just appears grayed out.
My first thought was that there were too many records, but there are only 1819 total records that need to be populated in the listbox. The strange thing is, if I restrict the number of rows to around 1500, everything appears fine. If I take that restriction away, nothing shows up in the listbox and the entire thing is grayed out.
My second thought was that the control was somehow getting its enabled property set to false. So I added in a line of code to ensure it was set to true before and after the update but this didn't make a difference.
Any thoughts? I can post sample code if needed, but it looks exactly like the function that is used for the first two tabs on the tab control and it populates those listboxes fine. The only difference I can see is that the number of records returned is significantly less for the first two, 5 and 10 records respectively.
Thanks in advance for any tips!
My first thought was that there were too many records, but there are only 1819 total records that need to be populated in the listbox. The strange thing is, if I restrict the number of rows to around 1500, everything appears fine. If I take that restriction away, nothing shows up in the listbox and the entire thing is grayed out.
My second thought was that the control was somehow getting its enabled property set to false. So I added in a line of code to ensure it was set to true before and after the update but this didn't make a difference.
Any thoughts? I can post sample code if needed, but it looks exactly like the function that is used for the first two tabs on the tab control and it populates those listboxes fine. The only difference I can see is that the number of records returned is significantly less for the first two, 5 and 10 records respectively.
Thanks in advance for any tips!