SUPER_USER SUPER_USER - 5 months ago 28
HTML Question

input button click event

I have input button and on this button i write some code. i select data from table and display in grid view when i click on button .. but when i select data from drop down and then when i click on button then button event no call?

i need to display data when i click on button

how i do this
code

protected void search_data_Click(object sender, EventArgs e)
{
//query
}

<input type="button" ID="search_data" runat="server" class="sear_btn" value="Search Data" onclick="search_data_Click" />


any solution?

Answer

You can use OnServerClick

<input type="button" value="Click me" runat="server" id="btnSave" OnServerClick="search_data_Click" />