Easy! Create a class level counter, set it to the number of iterations, and count it down in the Tick event:
Timer myTimer = new Timer();
myTimer.Interval = 20;
myTimer.Tick += new EventHandler(myTimer_Tick);
intervalCounter = 10;
myTimer.Start();
}
private int intervalCounter;
void myTimer_Tick(object sender, EventArgs e)
{
if (intervalCounter > 0)
{
intervalCounter--;
if (intervalCounter == 0)
{
intervalCounter = 10;
}
}
}