How do I get my newly created richtextbox inside my newly created tab?
The tab and richtextbox creator works fine, but how do I get it work. Right now it's just putting the RichTextBox behind the tab.
Code:Function NTab() Dim myTabPage As New TabPage myTabPage.Text = "Untitled" & (TabControl1.TabPages.Count + 1) TabControl1.TabPages.Add(myTabPage) Dim ControlCount As Integer Dim MyTextBox As RichTextBox MyTextBox = New RichTextBox Me.Controls.Add(MyTextBox) MyTextBox.Size = New System.Drawing.Size(0, 8) MyTextBox.Width = "600" MyTextBox.Height = "520" End Function




Reply With Quote