The CollapsiblePanel on it's own doesn't invoke a postback (seehttp://www.asp.net/AJAX/Control-Toolkit/Live/CollapsiblePanel/CollapsiblePanel.aspx)
My guess is that you have a server side control that is actually causing the postback that may be in the header...
-Damien
dwhite:
The CollapsiblePanel on it's own doesn't invoke a postback (seehttp://www.asp.net/AJAX/Control-Toolkit/Live/CollapsiblePanel/CollapsiblePanel.aspx)
My guess is that you have a server side control that is actually causing the postback that may be in the header...
-Damien
Yes I have a server control that invokes PostBack and that is trouble.
After postback whole page is reloaded, it happens after I place collapse panel on my page.
Try setting your UpdateMode on the UpdatePanel to Conditional. You shouldn't be seeing a full postback if the control is inside the UpdatePanel...
-Damien
dwhite:
Try setting your UpdateMode on the UpdatePanel to Conditional. You shouldn't be seeing a full postback if the control is inside the UpdatePanel...
-Damien
It didn't help. I see a full postback. This problems occurs only in IE6.
Are you using the ContentTemplate inside the UpdatePanel? I've seen people forget this and have issues... Seehttp://www.asp.net/ajax/documentation/live/overview/UpdatePanelOverview.aspx for an UpdatePanel overview.
Are you getting any script errors or anything?
Also see this:http://forums.asp.net/t/1096774.aspx
-Damien
This the way I use collapsible panel:
1 <asp:UpdatePanel ID="EditFormPanel" runat="server" UpdateMode="Always" ChildrenAsTriggers="True">
2 <ContentTemplate>
3
4<!--Collapsible panel-->
5 <table cellspacing="6" cellpadding="0" border="0">
6 <tr>
7 <td>
8<!--Header -->
9 <asp:Panel ID="generalInfoHeader" runat="server" CssClass="change-state-link">
10 <asp:ImageButton ID="generalInfoImg" runat="server" CssClass="btn-change-state" />
11 </asp:Panel>
12<!--Content -->
13 <asp:Panel ID="generalInfoContent" runat="server">
14 <table>
15
16 //Here I have some server controls, one of them invokes postback.
17
18
19 </table>
20 </asp:Panel>
21<!--toolkit extender-->
22 <ajaxToolkit:CollapsiblePanelExtender ID="cpeGeneralInfo" runat="server" TargetControlID="generalInfoContent"
23 ExpandControlID="generalInfoHeader" CollapseControlID="generalInfoHeader" Collapsed="False"
24 ImageControlID="generalInfoImg" ExpandedImage="/btn-change-state_plus.gif"
25 CollapsedImage="/btn-change-state_minus.gif" SuppressPostBack="true" />
26 </td>
27 </tr>
28 </table>
29<!--End collapsible panel-->
30
31 </ContentTemplate>
32</asp:UpdatePanel>
I haven't got any errors.
The thing is that when I write Height="0" Style="overflow:hidden;" in my'generalInfoContent' and it renders colapsed initially - it loads without flashing.
When panel is expanded & my inner control invokes postback there is no flashing, but because of Height="0" there is nothing in the panel.
If not to use height=0 flashing happens.
And I need my panel to be expanded initially.
Can you post a sample that can run directly without line number?
Have a look at this:http://blogs.visoftinc.com/archive/2007/09/23/asp.net-ajax--updatepanel-not-working--common-problems.aspx, check and make sure these common issues aren't affecting you.
-Damien
No comments:
Post a Comment