Very Basic Clock(Digital) - C#.net

All tutorials created in C# to be posted in here.
1 post Page 1 of 1
Contributors
User avatar
Agust1337
Coding God
Coding God
Posts: 2456
Joined: Fri Feb 19, 2010 8:18 pm

This is just a quick little basic clock that I want to share with everyone lol, hope you learn something of it :)
You'll need a Timer, the default interval(100), and Enabled, and of course a Label
Code: Select all
Timer1_Tick...
            DateTime DT = DateTime.Now;
            int Hour = DT.Hour;
            int Minute = DT.Minute;
            int Second = DT.Second;
            lblClock.Text = Hour + ":" + Minute + ":" + Second;
VB.net Tutorial
You're crazy!
I'm not crazy, my mother had me tested. ~Sheldon Cooper
1 post Page 1 of 1
Return to “C-Sharp Tutorials”