Solved

Visual Basic NOT allowing to create any control or menu item in MDI Form

Posted on 2008-06-18
5
498 Views
Last Modified: 2010-04-21
I am creating a visual basic application

The MDI Form has huge menu structure. Now I want to add further menu items, but Visual Basic is throwing the following message...!

Reached Limit : cannot create any more controls for this form

How to solve this ?
0
Comment
Question by:nds_rahulmistry
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 39

Accepted Solution

by:
appari earned 250 total points
ID: 21811072
is it is visual basic 6 or .net?

in vb6 if you reach the control limit, you can try using control array.
try  creating  the new menu controls with samename and define the index, it creates control array.
0
 
LVL 19

Assisted Solution

by:Stephen Manderson
Stephen Manderson earned 250 total points
ID: 21811333
I presume its vb6 because of the tags so..

Vb6 can only handle 254 named controls per form, you need to change your naming convention to allow for control arrays.

Such as text1.text, text2.text, text3.text would be changed to control arrays such that they would be named text(0).text, text(1).text, text(3).text

Regards
Steve
0
 
LVL 19

Expert Comment

by:Stephen Manderson
ID: 21811335
Heres the msdn reference for this issue

http://msdn.microsoft.com/en-us/library/aa265801(VS.60).aspx

Regards
Steve
0
 
LVL 3

Author Comment

by:nds_rahulmistry
ID: 21811374
IT IS VB6

AFTER I DELETED ONE TIMER CONTROL FROM THE DESIGN VIEW OF MDI FORM, NOW IT IS ALLOWING ME TO ADD MANY CONTROLS........!    

ACTUALLY, AFTER ABOVE MESSAGE, I WAS TRYING TO LOCATE UN-USED COMPONENTS OR CONTROLS. I FOUND ONLY THE TIMER CONTROL ON MY MDI FORM. I DELETED IT AND NOW ITS WORKING FINE.....!

ISN'T IT STRANGE ??

REGARDS,

RAHUL
0
 
LVL 3

Author Closing Comment

by:nds_rahulmistry
ID: 31468246
THANX
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Well, all of us have seen the multiple EXCEL.EXE's in task manager that won't die even if you call the .close, .dispose methods. Try this method to kill any excels in memory. You can copy the kill function to create a check function and replace the …
A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

740 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