[Mono-bugs] [Bug 73479][Wis] New - System.Web.UI.Control.FindControl - wrong behavior

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Tue, 8 Mar 2005 11:55:06 -0500 (EST)


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 ilyak@mainsoft.com.

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

--- shadow/73479	2005-03-08 11:55:06.000000000 -0500
+++ shadow/73479.tmp.2594	2005-03-08 11:55:06.000000000 -0500
@@ -0,0 +1,42 @@
+Bug#: 73479
+Product: Mono: Class Libraries
+Version: 1.1
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Wishlist
+Component: Sys.Web
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: ilyak@mainsoft.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: System.Web.UI.Control.FindControl - wrong behavior
+
+Description of Problem:
+Adding 2 or more Controls with same ID should cause HttpException when
+FindControl method is called.
+
+Steps to reproduce the problem:
+
+put following code in any Page_Load method:
+
+Label lab1 = new Label();
+lab1.ID = "TEST";
+Label lab2 = new Label();
+lab2.ID = "TEST";
+Controls.Add(lab1);
+Controls.Add(lab2);
+
+Control found = FindControl("TEST");
+
+Response.Write("found control is: " + found);
+
+Actual Results:
+returned first label 
+
+Expected Results:
+HttpException should be thrown