title: VB.NET MultiThreading Unlimited Threads
body: <p>I'm having a small issue with my program as it shows below, I want to use more than 1 thread but I have to dim each one and address each one to the specific sub, I've done this before but I haven't used VB.Net in a long time and I forgot how, any possible help? Thanks to anyone who reads/helps with this.</p>
  
  <pre><code>Imports System.Threading
  
  Public Class Form1
  
  Dim thread As System.Threading.Thread
  Dim ct as boolean = True
  
  Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
      thread = New System.Threading.Thread(AddressOf Main)
      thread.Start()
  End Sub
  
  Sub Main()
      Do Until ct = False
          'Executes something
      Loop
  End Sub
  
  End Class
  </code></pre>
  
  <p>Here's an example</p>
  
  <pre><code>Dim x As Integer = 1
  Private Sub asd()
      Do Until x = 50
          Dim thread &amp; x As System.Threading.Thread
          thread &amp; x = New System.Threading.Thread(AddressOf Main)
          thread &amp; x.Start()
          x = x + 1
      Loop
  End Sub
  </code></pre>
  
  <p>The above is an example that I want 50 thread, this doesn't work its just the idea.</p>