How to Get TextBox value from button click in Nested Gridview

前端 未结 2 566
别那么骄傲
别那么骄傲 2020-12-21 22:58

I have a Nested Gridview having textbox & Button column. How to display value of textbox in alert when Button Click by using jquer

2条回答
  •  轮回少年
    2020-12-21 23:40

    In your web.config add clientIDMode like this:

    
    

    Then:

    $(function() {
        $("#Button1").click(function(e) {
             e.preventDefault();
             alert($("#TextBox1").val());
        });
    });
    

提交回复
热议问题