By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
457,905 Members | 1,741 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 457,905 IT Pros & Developers. It's quick & easy.

Maximum number of controls in a form

P: n/a
M

There are a maximum number of controls can be put in a form for VB3 to VB6.
The BOL of VBNET do not say VBNET also has this limitation.

Because the clients want add more functions from time to time.
I find one of the form reach the maximum number of controls.
If I add one more control in this form, the program will get error at
InitializeComponent.

Are anyone find similar situation

Thanks


May 17 '06 #1
Share this Question
Share on Google+
5 Replies


P: n/a
you are only limited by the amount of available memory or 32K child
controls, whichever is less.

--
Get a powerful web, database, application, and email hosting with KJM
Solutions
http://www.kjmsolutions.com

"M" <mx****@hotvoice.com> wrote in message
news:uq**************@TK2MSFTNGP02.phx.gbl...

There are a maximum number of controls can be put in a form for VB3 to
VB6.
The BOL of VBNET do not say VBNET also has this limitation.

Because the clients want add more functions from time to time.
I find one of the form reach the maximum number of controls.
If I add one more control in this form, the program will get error at
InitializeComponent.

Are anyone find similar situation

Thanks

May 17 '06 #2

P: n/a
"M" <mx****@hotvoice.com> schrieb:
There are a maximum number of controls can be put in a form for VB3 to
VB6.
The BOL of VBNET do not say VBNET also has this limitation.
Basically there is no such strict limit as in VB6. However, the number of
controls on a form is limited by memory and other factors.
Because the clients want add more functions from time to time.
I find one of the form reach the maximum number of controls.
If I add one more control in this form, the program will get error at
InitializeComponent.


What's the exact error message? Maybe it's time to refactor the user
interface and split up the huge form.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

May 17 '06 #3

P: n/a
M,

We did some years ago a test in this newsgroup about how many controls where
possible.

The used number was so high that it would never be possible to put those in
a reasonable way on a form.

I hope this helps,

Cor

"M" <mx****@hotvoice.com> schreef in bericht
news:uq**************@TK2MSFTNGP02.phx.gbl...

There are a maximum number of controls can be put in a form for VB3 to
VB6.
The BOL of VBNET do not say VBNET also has this limitation.

Because the clients want add more functions from time to time.
I find one of the form reach the maximum number of controls.
If I add one more control in this form, the program will get error at
InitializeComponent.

Are anyone find similar situation

Thanks

May 18 '06 #4

P: n/a
M

Thanks.
But where do you find the 32K.
There are thousands controls in the form but I believed no reach 32K

"vbnetdev" <vb******@community.nospam> wrote in message
news:%2****************@TK2MSFTNGP03.phx.gbl...

you are only limited by the amount of available memory or 32K child
controls, whichever is less.

--
Get a powerful web, database, application, and email hosting with KJM
Solutions
http://www.kjmsolutions.com

"M" <mx****@hotvoice.com> wrote in message
news:uq**************@TK2MSFTNGP02.phx.gbl...

There are a maximum number of controls can be put in a form for VB3 to
VB6.
The BOL of VBNET do not say VBNET also has this limitation.

Because the clients want add more functions from time to time.
I find one of the form reach the maximum number of controls.
If I add one more control in this form, the program will get error at
InitializeComponent.

Are anyone find similar situation

Thanks



May 18 '06 #5

P: n/a
"M" <mx****@hotvoice.com> schrieb:
But where do you find the 32K.
There are thousands controls in the form but I believed no reach 32K


Really bad. I am wondering which controls you are using on the form. Maybe
some static controls such as labels and pictureboxes can be replaced by
drawing the text onto the form directly in its overridden 'OnPaint' method.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

May 18 '06 #6

This discussion thread is closed

Replies have been disabled for this discussion.