-
Mar 4th, 2012, 11:30 AM
#1
Thread Starter
New Member
Problems with TabControl
HI guys and gals
i am new to the forum and new to VB actualy only been doing vb for 2 weeks now, most the time i can get help from google and other sources but i am having problems finding what my problem is.
I have started a project that will help troubleshoot for customers and when i started the project i had not thought a head and now need to add Tabcontrol to my project.
As i said i am very new to this so please bare with me.
When i put in the tabcontrol none of my code works but when i undo everything until before i put the tabcontrol in my code works.
Let me know if you want me to past my code in.
Thanks for any help anyone can give me on this.
-
Mar 6th, 2012, 03:07 PM
#2
Re: Problems with TabControl
Welcome to VBForums
Thread moved from the 'Application Deployment' forum (which is for questions about installing/distributing your software) to he 'VB.Net' (VB 2002 and later) forum
For the benefit of others, er1k84's profile says VB 2010
-
Mar 6th, 2012, 04:27 PM
#3
Re: Problems with TabControl
I would paste the code here so that we could help you out a little bit. Just paste the part that isn't working, before and after. Otherwise, we really don't know how to help you.
-
Mar 6th, 2012, 04:37 PM
#4
Re: Problems with TabControl
are you putting your tab control on top of your form? where are your original controls?
More important than the will to succeed, is the will to prepare for success.
Please rate the posts, your comments are the fuel to keep helping people
-
Mar 7th, 2012, 12:03 AM
#5
Re: Problems with TabControl
If I had to guess, which I do, I'd say that you added the TabControl and then you cut and pasted your existing controls from the form into the TabPages. If so then you will have detached all your event handlers. When you create, for instance, a Click event handler for a Button, the IDE generates a method and adds a Handles clause to it to specify that it gets executed when the Button's Click event is raised. If you cut the Button, which is akin to deleting it, then the Handles clause is removed. If you then paste the Button, the Handles clause does not come back. The method still exists but it no longer handles the event.
To prevent this happening, do NOT cut and paste. Move your controls from one container to another either by dragging and dropping on the design surface or else by using the Document Outline window. That way your controls are never removed so the Handles clauses are never removed.
If the deed has already been done then there is a way to fix it. Open the Properties window and click the Events button at the top. Select a control and then, for each event you want handled, select the appropriate method from the adjacent drop-down list. Do that for each control and it will restore all your Handles clauses.
If that's not what happened then I've just wasted my time and you will need to provide a FULL and CLEAR description of EXACTLY what you did and EXACTLY what happened.
-
Mar 8th, 2012, 06:06 PM
#6
Thread Starter
New Member
Re: Problems with TabControl
jmcilhinney
perfect thats exactly what i did i have done what you suggested an all is working thanks again guys and sorry it took so long to get back to you.
On another issue not sure if i should raise it here or on another thread but after compiling the project it works fine on windows 7 32bit and 64 bit but will not work on server 2003 or xp clients have not checked vista yet, i have verified that .net 4 is installed and i can tell you that i do not get an error message when installing apart from the icon that i have given the project does not appear and is a blank icon on the desktop. When i try to run the program it will try to start i see the service in the task manager and after a while it will error out and crash. I can see the memory usage go from 20,000K to 70.000k.
Any ideas or would be most welcome
and thanks again for all your help to a new programmer
-
Mar 8th, 2012, 06:53 PM
#7
Re: Problems with TabControl
Originally Posted by er1k84
On another issue not sure if i should raise it here or on another thread but after compiling the project it works fine on windows 7 32bit and 64 bit but will not work on server 2003 or xp clients have not checked vista yet, i have verified that .net 4 is installed and i can tell you that i do not get an error message when installing apart from the icon that i have given the project does not appear and is a blank icon on the desktop. When i try to run the program it will try to start i see the service in the task manager and after a while it will error out and crash. I can see the memory usage go from 20,000K to 70.000k.
Look at the title of this thread. That will tell you whether this new question belongs in this thread. One thread per topic and one topic per thread.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|