ayozzhero
Well-known member
Dim editmode as boolean
Private Sub UpperPart_KeyPress(ByVal sender As Object, _
ByVal e As System.Windows.Forms.KeyPressEventArgs) _
Handles txtCBName.KeyPress, txtAccNo.KeyPress, _
txtNote.KeyPress, txtChequeNo.KeyPress, txtAddress.KeyPress
e.Handled = Not editmode
End Sub
That is a part of my code. How do I detect in which control (textbox) actually the key is pressed. e.g. I want to display (msgbox) the textbox content everytime a key is pressed in the textbox
Thank you
Private Sub UpperPart_KeyPress(ByVal sender As Object, _
ByVal e As System.Windows.Forms.KeyPressEventArgs) _
Handles txtCBName.KeyPress, txtAccNo.KeyPress, _
txtNote.KeyPress, txtChequeNo.KeyPress, txtAddress.KeyPress
e.Handled = Not editmode
End Sub
That is a part of my code. How do I detect in which control (textbox) actually the key is pressed. e.g. I want to display (msgbox) the textbox content everytime a key is pressed in the textbox
Thank you