I can't seem to get the accordion to databind at all. If I put in the static panels, it appears, but when I databind, nothing shows up. My ultimate goal is to have a repeater of accordions. I am doing an FAQ page, and I have groups for the FAQ's (the repeater) and then the questions for each group (the accordian). I am dropping an ID I need into an invisible label and pulling it out on databind of the repeater to pull in the data I need for the accordion. However, it isn't appearing.
So, for a test I put in an accordion with static defined panels and all works fine. I even tried databinding to an accordion outside the repeater, and no luck there either.
Here is my aspx page. I am using Master Pages. In the back, all I am doing is a databind of a System.Data.DataTable to accordianFAQTest. Ignore the repeater for now.
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolderPage" Runat="Server">
<asp:ScriptManager ID="scriptManager" runat="server" />
<asp:Repeater ID="repeaterFAQ" runat="server" OnItemDataBound="repeaterFAQ_ItemDataBound">
<ItemTemplate>
<h2><%# DataBinder.Eval(Container.DataItem, "DisplayText") %></h2>
<asp:Label ID="labelId" runat="server" Visible="false" Text='<%# DataBinder.Eval(Container.DataItem, "FAQGroupId") %>' />
<ajaxToolkit:Accordion ID="accordianFAQ" SuppressHeaderPostbacks="true" runat="server" >
<HeaderTemplate>Test<%# Eval("QuestionText") %></HeaderTemplate>
<ContentTemplate>Test<%# Eval("AnswerText") %></ContentTemplate>
</ajaxToolkit:Accordion>
<asp:Panel ID="panelNoHelpTopics" runat="server" Visible="false">
There are no help topics available for this group.
</asp:Panel>
<br />
</ItemTemplate>
</asp:Repeater>
<ajaxToolkit:Accordion ID="accordianFAQTest" SuppressHeaderPostbacks="true" runat="server" >
<HeaderTemplate><%# DataBinder.Eval(Container.DataItem, "QuestionText") %></HeaderTemplate>
<ContentTemplate><%# DataBinder.Eval(Container.DataItem, "AnswerText")%></ContentTemplate>
</ajaxToolkit:Accordion>
<asp:Panel ID="panelNoHelp" runat="server" Visible="false">
There are no help topics available.
</asp:Panel>
</asp:Content>
Does anyone know why the accordion isn't showing when databinding?
Thanks
Loki