views:

317

answers:

1

Hi, I'm using MS AJAX's accordion control. It works fine normally, but I can't seem to get it to work with an UpdatePanel. My layout is like this:

    <div id="accordion">
     <div><a href="#">Header1</a></div>

        <div class="acc_content">  
    <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional"  >

    <ContentTemplate>
    <asp:button id="btnToggle" runat="server" text="toggle"/>

  //my repeater contents go here. The buttons within the repeater cause a postback, but changes cannot be seen unless the page is manually refreshed (since the updatepanel doesn't refresh)
    </ContentTemplate>

    <Triggers>
    <asp:AsyncPostBackTrigger ControlID="btnToggle" EventName="click" />
    <asp:AsyncPostBackTrigger ControlID="btnAdd" EventName="click" /> //this button is outside the updatepanel


    </ContentTemplate>
    </Triggers>
    </asp:UpdatePanel>
    </div>

    <div><a href="#">Header 2 </a></div>
      <div class="acc_content">  
          Content of the second pane
          </div>



    </div>

There are postbacks occurring when I click the buttons, but the updatepanel never refreshes or updated. I tried adding UpdatePanel1.Update() in the code-behind for each postback event, but no luck. Any ideas as to why this is happening?

Thanks

A: 

I managed to solve it. For those who run into similar issues, I added an extra script reference in my ScriptManager:

<asp:ScriptReference Name="MicrosoftAjaxWebForms.js" Path="http://ajax.microsoft.com/ajax/beta/0911/MicrosoftAjaxWebForms.js" />
keyboardP