Link to home
Start Free TrialLog in
Avatar of externet
externet

asked on

onTextChanged event will not fire


Hi,

When the text changes, the event does not fire.
Public Sub txtNotes_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs)
          txtNotes.Attributes.Add("onTextChanged", "javascript:return confirm('Data has Changed. Click OK To Continue');")
End Sub

Your help is appreciated.
Avatar of tusharashah
tusharashah

Well you need to add this line in Page_load not inside txtNotes_TextChanged

--> txtNotes.Attributes.Add("onTextChanged", "javascript:return confirm('Data has Changed. Click OK To Continue');")
    'Add this line in Page_Load

-tushar
ASKER CERTIFIED SOLUTION
Avatar of tusharashah
tusharashah

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of externet

ASKER

Excellent! -tushar!
here is my final answer and it works as expected.
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        txtNotes.Attributes.Add("onchange", "javascript:return confirm('Data has Changed. Click OK To Continue');")
End Sub

Thanks for a quick response.
externet.
Nice to have you going externet!

Thanks for A :)

-tushar
Thank you  tusharashah.