I have created dynamic timer. That takes different time intervals. But all the information are appearing one time. I want each piece of information will appear just after its time is over.
How can I do that?
private void btnTest_Click(object sender, EventArgs e)
{
for (int x = 0; x <= 5; x++)
{
System.Timers.Timer timer = new System.Timers.Timer();
timer.AutoReset=true;
timer.Start();
timer.Interval = ((x + 1) * 100);
this.txtOutput.Text += "\r\r\n" + " this out put equal to " + ((x + 1) * 100);
Thread.Sleep((x + 1) * 100);
this.txtOutput.Text += "\r\r\n" + " Ends x " + x;
}
}