IneedaSmoke
Active member
- Joined
- Mar 4, 2008
- Messages
- 26
- Programming Experience
- Beginner
Hey all, wondering if anyone knew whether or not multi thread tab control could work.
I have a tab control that I create tabs programmatically. I tried creating the tabs as new threads, but i'm getting thread conflict errors.
I have a tab control that I create tabs programmatically. I tried creating the tabs as new threads, but i'm getting thread conflict errors.
HTML:
Private Sub loadTCTabs(ByVal productList As ArrayList)
For Each item In productList
positionCounter.addALClasses(item)
Dim newThread As Thread
newThread = New Thread(AddressOf createTab)
newThread.Start()
Next
End Sub
Private Sub createTab()
Dim newTab As New TabPage
Dim newDGV As New DataGridView
Dim positionData As New ArrayList
positionData = positionCounter.getCurrentValueClassCounterPosition
newTab.Text = positionData(1)
newTab.Controls.Add(newDGV)
newDGV.Width = 815
newDGV.Height = 606
newDGV.Location = New System.Drawing.Point(0, 3)
tcOutput.TabPages.Add(newTab)
End Sub