How change value from keypress_event ?

  • Thread starter Thread starter PocketPC
  • Start date Start date
P

PocketPC

Hi,

How can I change the value of a key in the keypress event ?

Private Sub TextBox1_KeyPress(ByVal sender As Object, ByVal e As
System.Windows.Forms.KeyPressEventArgs) Handles TextBox1.KeyPress

if e.keychar=chr(13) then ....[??????????]-> value to change

End Sub

Thanks in advance
 
KeyChar is readonly meaning it only has a Get implemented. You can set the Handled property to true and put the appropriate character in the textbox via code.
 
Back
Top