I write code using VB.net like:
Dim a As Thread
Dim i As Integer
[B] Private Sub Form1_Load[/B]
For i = 1 To 5
a = New Thread(New ThreadStart(AddressOf coba))
a.Start()
Next
[B] End Sub[/B]
[B]Sub coba()[/B]
MsgBox(i)
a.Sleep(500)
[B]End Sub[/B]
why result different sometimes:
display MessageBox with text 1 ,3,3,5 and 6
every executed,the result different
i want display result 1,2,3,4,5
what's wrong with my coding?
plz help me
thanx