?
Solved

Max items in Listbox control

Posted on 2004-11-22
7
Medium Priority
?
630 Views
Last Modified: 2012-06-27
Can anyone tell me: what is maxium items can be added to the list box control?10,000? thanks
0
Comment
Question by:shyline777
5 Comments
 
LVL 28

Expert Comment

by:vinnyd79
ID: 12646262
I think the limit only applies to Win9.x, which the max is 32,767
0
 
LVL 26

Accepted Solution

by:
EDDYKT earned 120 total points
ID: 12646588
I think you can add more than 32,767 but you have only access the first 32,767
0
 

Author Comment

by:shyline777
ID: 12648071
THANKS
0
 
LVL 11

Expert Comment

by:Louis01
ID: 12664263
If you look in VB's Object browser, you'll see that the Listindex property is of type Integer.

Thus the limit is the integer limit - 32767 (Making it 32768 possible items in a listbox)
0
 
LVL 1

Expert Comment

by:dragonfire123
ID: 12730238
Agreed, ran a test on this, to add a new item into a listbox iteratively, exiting either when an error was reached or when the list count was greater than 32767.  Error generated @ 32767.  It'll let you keep adding, but you can't get at any of the items, and it throws your count way out of whack.  (ListCount starts returning negative numbers)
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Suggested Courses
Course of the Month14 days, 17 hours left to enroll

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question