private void timer2_Tick(object sender, EventArgs e)
        {
            lbltime.Text = DateTime.Now.ToString();
            if (DateTime.Now.Hour == 19 && DateTime.Now.Minute == 41 && DateTime.Now.Second == 50)
            {
                SoundPlayer sp = new SoundPlayer();
                sp.SoundLocation = @"D:/c/hh.wav";
                sp.Play();
            }
        }

 

相关文章: