Multiple Event Handling for the Lazy Ones





5.00/5 (1 vote)
why not just create a custom handler for all the textboxes? addhandler textbox1.textchanged, addressof textchangedhandler addhandler textbox2.textchanged, addressof textchangedhandler .... 'add additional textbox handlers .... addhandler textbox7.textchanged, addressof...
why not just create a custom handler for all the textboxes?
addhandler textbox1.textchanged, addressof textchangedhandler
addhandler textbox2.textchanged, addressof textchangedhandler
....
'add additional textbox handlers
....
addhandler textbox7.textchanged, addressof textchangedhandler
For the customer handling routine
private sub TextchangedHandler(ByVal sender As System.Object, ByVal e As System.EventArgs)
'....
'Do sub code
'....
end sub