PDA

View Full Version : Checkbox value not saved inside collapsible control (ie6)



Benoit
Jul 16, 2008, 8:23 AM
Hello,

I've found an issue with collapsible controls that affect ie6 only (tested also with FF & ie7, ext 0.5.4).
All asp checkbox and radiobutton inside ext controls like accordion and collapsible panel dont keep their value when you collapse them.

Other controls like DropdownList are not affected. Ext controls (the ext checkbox for exemple) arn't too.

So the big problem is for checkoxlist : there is no equivalent control with ext !

Here you can find find a sheet of code that explain the bug (so with ie6...)



<%@ Page Language="C#" AutoEventWireup="true" Title="CheckBox tests" %>

<%@ Register Assembly="Coolite.Ext.Web" Namespace="Coolite.Ext.Web" TagPrefix="ext" %>

<script runat="server">

</script>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title>CheckBox</title>
</head>
<body >

<form id="form" runat="server">

<ext:ScriptManager ID="ScriptManager1" runat="server">
</ext:ScriptManager>

<ext:Panel ID="PanelCollapsible" runat="server" Height="300" Title="Panel Collapsible" Collapsible="true">
<Content>
<asp:CheckBoxList ID="CheckBoxList1" runat="server">
<asp:ListItem Text="Panel CBL 1"></asp:ListItem>
<asp:ListItem Text="Panel CBL 2 checked" Selected="True"></asp:ListItem>
</asp:CheckBoxList>
<hr />
<asp:CheckBox ID="CheckBox7" runat="server" Text="CheckBox 1 checked" Checked="true" />
<asp:CheckBox ID="CheckBox8" runat="server" Text="CheckBox 2" />
<hr />
<ext:Checkbox ID="Checkbox9" runat="server" FieldLabel="ext Checkbox 1" >
</ext:Checkbox>ext CB 1 is working
<ext:Checkbox ID="Checkbox10" runat="server" FieldLabel="ext Checkbox 2 checked"
Checked="true" >
</ext:Checkbox>ext CB 2 checked is working
<hr />
<asp:RadioButtonList ID="RadioButtonList1" runat="server">
<asp:ListItem Text="rbl1 checked" Selected="True"></asp:ListItem>
<asp:ListItem Text="rbl2 checked"></asp:ListItem>
</asp:RadioButtonList>
<hr />
<asp:DropDownList ID="DropDownList1" runat="server">
<asp:ListItem Text="no value"></asp:ListItem>
<asp:ListItem Text="It Works !"></asp:ListItem>
</asp:DropDownList>
</Content>
</ext:Panel>

<ext:Panel ID="PanelAccordion" runat="server" Height="300" Title="Panel accordion">
<Content>
<ext:Accordion ID="Accordion1" runat="server" Animate="true">
<ext:Panel ID="Panel2" runat="server" Border="false" Title="Item 1">
<Content>
<asp:CheckBox ID="CheckBox1" runat="server" Text="CheckBox1 checked" Checked="true" />
<asp:CheckBox ID="CheckBox2" runat="server" Text="CheckBox2" />
</Content>
</ext:Panel>
<ext:Panel ID="Panel3" runat="server" Border="false" Collapsed="true" Title="Item 2">
<Content>
<asp:CheckBoxList ID="CheckBoxList2" runat="server">
<asp:ListItem Text="ListItem1 checked" Selected="True"></asp:ListItem>
<asp:ListItem Text="ListItem2"></asp:ListItem>
</asp:CheckBoxList>
</Content>
</ext:Panel>
</ext:Accordion>
</Content>
</ext:Panel>

<ext:Window ID="WindowAccordion" runat="server" Height="300" Title="Window accordion">
<Content>
<ext:Accordion ID="Accordion2" runat="server" Animate="true">
<ext:Panel ID="Panel1" runat="server" Border="false" Title="Item 1">
<Content>
<asp:CheckBox ID="CheckBox5" runat="server" Text="CheckBox1" />
<asp:CheckBox ID="CheckBox6" runat="server" Text="CheckBox2 checked" Checked="true" />
</Content>
</ext:Panel>
<ext:Panel ID="Panel4" runat="server" Border="false" Collapsed="true" Title="Item 2">
<Content>
<asp:CheckBoxList ID="CheckBoxList4" runat="server">
<asp:ListItem Text="ListItem1 checked" Selected="True"></asp:ListItem>
<asp:ListItem Text="ListItem2"></asp:ListItem>
</asp:CheckBoxList>
</Content>
</ext:Panel>
</ext:Accordion>
</Content>
</ext:Window>

<ext:FieldSet ID="FieldSet1" runat="server" Collapsible="true" Title="Fieldset is working well !">
<Content>
<asp:CheckBoxList ID="CheckBoxList3" runat="server">
<asp:ListItem Text="FS CBL 1"></asp:ListItem>
<asp:ListItem Text="FS CBL 2 checked" Selected="True"></asp:ListItem>
</asp:CheckBoxList>
<hr />
<asp:CheckBox ID="CheckBox3" runat="server" Text="CheckBox 1" />
<asp:CheckBox ID="CheckBox4" runat="server" Text="CheckBox 2 checked" Checked="true" />
</Content>
</ext:FieldSet>

</form>

</body>
</html>



The only exception seem to be the collapsible FieldSet !!

Benoit
Jul 21, 2008, 8:03 AM
Hello,

I've a temporary solution :

The problem is due to the collapse animation. So using AnimCollapse="false" on panel or Animate="false" on accordion let get them working with the right behavior !

An idea if this will be corrected in next release ?

Thanks


Benoit