You must Sign In to post a response.
  • Category: ASP.NET

    Need detail about textbox changed event

    Dear Friends
    I have written one c# method with some calculation. now i called that method in textbox changed event. when i was run that that method does not fired. i dont know why it will happened.

    can any one guide me friends
  • #763229
    Hi navaneethakrishnan.

    You need to make the autopostback property of textbox to true, then the textbox_TextChanged event will fire.
    Go to textbox properties
    Or other way you can do by taking a button control on button click it will work for you.

    protected void txtname_TextChanged(object sender, EventArgs e)
    Response.Write("am from txtchanged event");
    //your calculation

    Sridhar Thota.
    Editor: DNS Forum.

  • #763230

    Refer below syntax for firing
    textbox changed event of textbox.

    <asp:TextBox ID="TextBox1" runat="server" AutoPostBack="True"

    Give respect to your work, Instead of trying to impress your boss.

    Blog :

  • #763346
    Are you using Client side text box or Server side text box?

    If it is server side text box enable AutoPostBack="True"
    If it is the Client Side text box we have to use "onchange" event and use the javascript.

    By Nathan
    Direction is important than speed

Sign In to post your comments