Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Catch enter key
Message
De
28/09/2005 00:19:58
 
Information générale
Forum:
ASP.NET
Catégorie:
Formulaires
Titre:
Versions des environnements
Environment:
VB.NET 1.1
OS:
Windows XP SP2
Network:
Windows XP
Database:
MS SQL Server
Divers
Thread ID:
01053288
Message ID:
01053749
Vues:
16
Thank's Einar, the problem is that the textbox of the datagrid column doesn't catch the keyup event.

>>I am trying to find the way to catch when user press enter key on a datagrid cell and perform a method inside the form, i am using a selector form wich contains a datagrid as that one of Les Pinter's book in which he uses a "select" button to select the record, i could catch double click event in the textbox of the column that contains the key field through an event handler which catch's double clik on that particular textbox i want to do the same pressing "enter" key.
>>I hope you 'd understood me and thank's in advance.
>
>Juan,
>There are atleast two events you can use for this: KeyUp and KeyPress.
>Here is some code where I used KeyUp (it is C# but it should be easy to translate into VB.NET)
>
>private void textBox1_KeyUp(object sender, System.Windows.Forms.KeyEventArgs e)
>{
>	if (e.KeyCode == System.Windows.Forms.Keys.Enter)
>	{
>		MessageBox.Show("Enter button was pressed");
>	}
>}
>
>
>Hope this helps.
>
>Einar
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform