[Mono-bugs] [Bug 58497][Cri] New - MONO Beta 1 Bug with Disabled Controls losing ViewState

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Fri, 14 May 2004 06:38:46 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by davidandrewtaylor@hotmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=58497

--- shadow/58497	2004-05-14 06:38:46.000000000 -0400
+++ shadow/58497.tmp.4342	2004-05-14 06:38:46.000000000 -0400
@@ -0,0 +1,54 @@
+Bug#: 58497
+Product: Mono: Class Libraries
+Version: unspecified
+OS: Red Hat 9.0
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 002 Two hours
+Priority: Critical
+Component: Sys.Web
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: davidandrewtaylor@hotmail.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: MONO Beta 1 Bug with Disabled Controls losing ViewState
+
+Description of Problem:
+Major bug in MONO Beta 1 in that any controls that are set to disabled 
+(ie Control.Enabled=false) lose their ViewState when the page is posted 
+back.  This works correctly in MS.NET but fails in MONO Beta 1
+
+Steps to reproduce the problem:
+<%@Page %>
+<script runat="server" language="c#">
+void Page_Load(object sender, EventArgs e)
+{
+	if (!Page.IsPostBack) 
+	{
+		MyList.Enabled=false;
+		MyText.Text = "Hi Friends";
+		MyText.Enabled=false;
+	}
+}
+</script>
+<html><body><form runat="server">
+
+<asp:CheckBoxList id="MyList" runat="server">
+	<asp:ListItem Value="Hello" />
+</asp:CheckBoxList>
+<asp:TextBox id="MyText" runat="server" Text="Hi" />
+<asp:Button runat="server" Text="Click Me" />	
+</form></body></html>
+
+Actual Results:
+Control property values stored in ViewState are lost.
+
+Expected Results:
+Controls should keep their properties (stored in ViewState) even if the 
+control is disabled.
+
+How often does this happen? 
+All the time on MONO Beta 1.