private void btnStart_Click(object sender, EventArgs e)
{
timer1.Interval = 100;
Add -> timer1.Tick += timer1_Tick
TimerEnd = false;
label1.Text = "Process Started...";
timer1.Enabled = true;
while (!TimerEnd) ;
label1.Text = "Process Finished";
}
private void timer1_Tick(object sender, EventArgs e)
{
counter++;
if (counter > 10)
{
TimerEnd = true;
counter = 0;
}
}
You never set the event handler.