closet geek
Newcomer
- Joined
- Apr 2, 2006
- Messages
- 21
Hi,
I have a program that needs multiple tabs. The tabs are created when a user clicks a button and these created tabs are clones of the initial tab (which has a richtexbox on it).
I have a couple of questions.
1) How do I allow for unlimited tab creation - so instead of me defining a tab name I can say to J#: "Name the tab tabPage[integer] and after every creation do [integer]++". Currently I'm just using:
Which does allow multiple tabs to be open but do these have the same name?
2) How do I reference the richtextboxes that are created when a new tab is created? How do I ensure each richtext box that is created has a unique identifier (as with the tabs)?
I'm currently just using this, again it creates a richtextbox no matter how many tabs I create but I'm not sure how to reference the richtextbox:
Thanks a lot.
I have a program that needs multiple tabs. The tabs are created when a user clicks a button and these created tabs are clones of the initial tab (which has a richtexbox on it).
I have a couple of questions.
1) How do I allow for unlimited tab creation - so instead of me defining a tab name I can say to J#: "Name the tab tabPage[integer] and after every creation do [integer]++". Currently I'm just using:
Code:
TabPage tabPage2 = new TabPage("tab");
tabControl1.get_TabPages().Add(tabPage2);
Which does allow multiple tabs to be open but do these have the same name?
2) How do I reference the richtextboxes that are created when a new tab is created? How do I ensure each richtext box that is created has a unique identifier (as with the tabs)?
I'm currently just using this, again it creates a richtextbox no matter how many tabs I create but I'm not sure how to reference the richtextbox:
Code:
RichTextBox richTextBox1 = new RichTextBox();
tabPage2.get_Controls().Add(richTextBox1);
Thanks a lot.