Timer1.Start(); // Timer in initialized.
private void timer1_Tick(object sender, EventArgs e) { bool status = false; label1.Text = DateTime.Now.ToLongTimeString(); DateTime time = Convert.ToDateTime("10:05:00 PM"); if (DateTime.Now.ToLongTimeString() == time.ToLongTimeString()) { MessageBox.Show("Perfect Code.", "Timer Control", MessageBoxButtons.OK, MessageBoxIcon.Information); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)