Alert user with beep sound for invalid entries using C#
Many times when we alert the user with some messages but the user doesn’t heed immediately. A combination of sound and popup should be more helpful. The following example would alert the user if he/she hasn’t input the required field
private void buttonOK_Click(object sender, EventArgs e)
{
if (txtExcelFile.Text.Length == 0)
{
System.Console.Beep();
MessageBox.Show ("Select the file and continue...");
}
}
Windows User Form
For a Rhyming Beep peep at http://dotnetdud.blogspot.com/2009/01/how-to-create-rhyming-beeps-in-c.html
No comments:
Post a Comment