i have been using a program called angry ip scanner for awhile now to help me when i am working on networks. well i like it and i dont. i would like to make my own with a feature that angry doesnt have. i have the ping working and everything, i just would like to make it multithreaded so it will run faster. currently it takes 5 seconds for it to do 1 ip address so you can imagine what it takes to do 254. so, i am calling a class that does the pinging, i just would like to create like 30 threads or so so i am scanning more then one at a time. this is the code i use to call the class, now i would like to know how to make it threaded. thanks in advance. gold star to whoever helps me.
Code:
private void button3_Click(object sender, EventArgs e)
{
int f4int = Convert.ToInt32(F4.Text);
int t4int = Convert.ToInt32(T4.Text);
for (int z = f4int; z <= t4int; z++)
{
Class1 cls = new Class1();
string tmp;
\\where i call the class
tmp = cls.Trd(z, F1.Text.ToString(), F2.Text.ToString(), F3.Text.ToString(), f4int, t4int);
textBox1.AppendText(tmp);
progressBar2.Increment(2);
}
}