PROKA Posted November 17, 2003 Posted November 17, 2003 ok so here's the deal . the cursor is inside a textbox . Whenever I press a key, instead of the character appearing in the textbox, I want to handle an event and do something else Quote Development & Research Department @ Elven Soft
*Experts* Volte Posted November 17, 2003 *Experts* Posted November 17, 2003 In the KeyPress event, set e.Handled = True to cancel the keypress from taking effect. Quote
PROKA Posted November 17, 2003 Author Posted November 17, 2003 could u be more specific ? with some code maybe ... I'm new to vb Quote Development & Research Department @ Elven Soft
*Experts* jfackler Posted November 17, 2003 *Experts* Posted November 17, 2003 Private Sub TextBox1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles TextBox1.KeyPress e.Handled = True 'add the code to process the keypress event here End Sub Jon Quote
PROKA Posted November 17, 2003 Author Posted November 17, 2003 It underlines System.Windows.Forms.KeyPressEventArgs uh ... Imports ... something ? :-\ Quote Development & Research Department @ Elven Soft
Administrators PlausiblyDamp Posted November 17, 2003 Administrators Posted November 17, 2003 What is the error it gives? Everything else in the form works okay though? Also you are doing this in a windows form project aren't you? Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
PROKA Posted November 18, 2003 Author Posted November 18, 2003 nope, it's an ASP.NET Web Application uh ... oups ? Quote Development & Research Department @ Elven Soft
PROKA Posted November 22, 2003 Author Posted November 22, 2003 Nope , nobody, no ideea, uh ? :(( Quote Development & Research Department @ Elven Soft
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.