Hi I am trying to enumerate through 3 levels of directory structure/folders and create TabPages with the names same as the directory names. Further I want to add controls to these TabPages created at runtime.
I have tried to create TabPages with the following commands:
Dim tabcontrol1 As New TabControl Dim tabpagecollection1 As New TabControl.TabPageCollection(tabcontrol) tabpagecollection1.Add("Page1") tabcontrol1.TabPages.Add("TabPage1", "Page2")
But with the above commands I can't add controls to the TabPages and if I use the following command:
Dim tabpage1 As New TabPage tabcontrol1.Controls.Add(tabpage)
Then I can't figure out how to declare variables dynamically.