views:

150

answers:

6

Hi,

I have a C# web form with a search button and some search criteria. But after adding an AJAX panel, the search button won't post back.

Any idea?

Thanks in advance!

+2  A: 

Really, it would help a lot if you could post your code. There's no way to diagnose anything otherwise.

My first guess is that there is a javascript error somewhere on the page.

womp
A: 

Do you have UseSubmitBehavior="true" on the button? Also, check the UpdateMode attribute on the UpdatePanel.

ajh1138
A: 

Is there any Javascript error happening on the page like Sys is undefined etc?

Ramesh
A: 

Also check for nested form tags. We had a user control with a standard html form <form action = "someotherpage.asp">, and when this user control was nested inside the <form runat="Server"> tags, we would get this behavior.

David Stratton
A: 

Is the search button within the UpdatePanel? If so, you need to add a PostBackTrigger in teh triggers for the search button. This goes in the Triggers section of the UpdatePanel control.

Jeff Siver
A: 

if you realy want to postback, plz use this .... put this in page load event

ScriptManager.GetCurrent(this).RegisterPostBackControl(yourbuttonID);
Muhammad Akhtar