Hello Everybody !!!
I have the problem about my Digital Clock, You could see this on my attachment.
It works perfectly, but one problem that when the second == 10, the label name second lblSed appear "010", when it's up to 11, it appear normally. I dont know what wrong with that.
Thanks for helping !!!
My timer Even code:
timer1.Interval = 1000;
if (sed >= 10 || min >= 10 || hour >= 10)
{
sed++;
lblSed.Text = sed.ToString();
if (sed == 60)
{
sed = 0;
min++;
lblMin.Text = min.ToString();
}
if (min == 60)
{
min = 0;
hour++;
lblHour.Text = hour.ToString();
}
}
else
{
if (sed < 10 || min < 10 || hour < 10)
{
sed++;
lblSed.Text = "0" + sed.ToString();
if (sed == 60)
{
sed = 0;
min++;
lblMin.Text = "0" + min.ToString();
}
if (min == 60)
{
min = 0;
hour++;
lblHour.Text = "0" + hour.ToString();
}
}
}
Digital_Clock.zip