Added code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace passGL
{
public partial class UserLogin : Form
{
public UserLogin()
{
InitializeComponent();
}
private void label1_Click(object sender, EventArgs e)
{
}
private void UserLogin_Load(object sender, EventArgs e)
{
}
private void txtBxUserID_TextChanged(object sender, EventArgs e)
{
// if (e.KeyChar == Keys.M) e.Handled = true;
// if (e.Equals( Keys.M ) )
// {
// Console.WriteLine("Enter pressed!!");
// }
}
}
}
"Jerry" <jp******@general-steel.comwrote in message
news:12*************@corp.supernews.com...
Hello,
I have put a simple form together with a lable and a textbox. I want to
be able to trap the ENTER key when is pressed. So I can check the texted
enetered. If correct, call up the main program, if not re-prompt for the
user ID.
Thanks,
Jerry