I have two update modules inside the accordion control laid out as follows:
<accordion> <first pane content> <updatepanel UpdateMode="conditional"> <contenttemplate>...</contenttemplate> <triggers>...</triggers> </updatepanel> </first pane content> <second pane content> <updatepanel> <contenttemplate>...</contenttemplate> <triggers>...</triggers> </updatepanel> </second pane content> </accordion>
The panel is updated once, but after this update does not occur. If I refresh the page, I can see the updated information. This means that the database is being updated, but the updated panel is not refreshing (after updating for the first time). Why is this happening?
This listened to me for several days, so any advice would be greatly appreciated. Thanks!
Update
It seems that the problem is what I call this:
Sys.require(Sys.components.accordion, function() { $("#acca_profile").accordion({ HeaderCssClass: "acc_header", HeaderSelectedCssClass: "acc_selectedheader", FadeTransitions: true, suppressHeaderPostbacks: true, requireOpenedPane: false }); });
in the endRequestHandler function. However, if I do not name it, then the div that should be converted to an accordion is no longer an accordion.
Update 2
After a bit of extra work, I decided that the problem might be that jQuery does not recover events after a partial postback. Many solutions claim that you need to register a client script, but I have this at the top of my aspx page:
<asp:ScriptManager runat="server" EnablePageMethods="true"> <Scripts>
... (other script) Path = "http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" / ">
</Scripts> </asp:ScriptManager>
How can I reorder jQuery events in my code?