Bug 313011 (MONO49927) - RangeValidator results in exception
Summary: RangeValidator results in exception
Status: RESOLVED FIXED
Alias: MONO49927
Product: Mono: Class Libraries
Classification: Mono
Component: Sys.Web (show other bugs)
Version: unspecified
Hardware: Other All
: P3 - Medium : Major
Target Milestone: ---
Assignee: Gonzalo Paniagua Javier
QA Contact: Mono Bugs
URL:
Whiteboard:
Keywords: UI
Depends on:
Blocks:
 
Reported: 2003-10-21 16:09 UTC by Yaron Shkop
Modified: 2007-09-15 21:24 UTC (History)
0 users

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
Testcase (1.49 KB, text/plain)
2003-10-21 16:10 UTC, Thomas Wiest
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Wiest 2007-09-15 18:17:55 UTC


---- Reported by yaronsh@mainsoft.com 2003-10-21 09:09:20 MST ----

Please fill in this template when reporting a bug, unless you know what 
you are doing.
Description of Problem:
Using range validator on Date validating results an exception 

Steps to reproduce the problem:
1. Open the attached aspx

Actual Results:
Exception.

This is the highlight of the exception:
System.Web.HttpException: Validator_value_bad_type: 2001/1/1 MaximumValue 
rangeValDate Date 
in <0x00156> 
System.Web.UI.WebControls.RangeValidator:ControlPropertiesValid ()
in <0x00021> System.Web.UI.WebControls.BaseValidator:get_PropertiesValid ()
in <0x0009a> System.Web.UI.WebControls.BaseValidator:Render 
(System.Web.UI.HtmlTextWriter)
in <0x0001c> System.Web.UI.Control:RenderControl 
(System.Web.UI.HtmlTextWriter)


Expected Results:
A page with textbox for date range validation 

How often does this happen? 
Always



---- Additional Comments From yaronsh@mainsoft.com 2003-10-21 09:10:40 MST ----

Created an attachment (id=165088)
Testcase




---- Additional Comments From yaronsh@mainsoft.com 2003-10-21 09:25:16 MST ----

I think the problem is at BaseCompareValidator.Convert()



---- Additional Comments From yaronsh@mainsoft.com 2003-10-22 10:39:27 MST ----

Is the bug in corlib?? I don't think so... I work with different 
corlib and the problem is the same... I don't think this praticular 
problem is in corlib...



---- Additional Comments From gonzalo@ximian.com 2003-10-22 11:43:01 MST ----

Now we get a little further. The page is rendered.




---- Additional Comments From gonzalo@ximian.com 2003-10-23 08:49:30 MST ----

Fixed in CVS.



---- Additional Comments From yaronsh@mainsoft.com 2003-10-23 09:12:13 MST ----

Was it in System.Web?



---- Additional Comments From gonzalo@ximian.com 2003-10-23 09:45:37 MST ----

The last part, yes. There was a bug in DateTime.cs too (fixed by Dick)
too.

I only changed && by || in the first Match to make this work.



---- Additional Comments From yaronsh@mainsoft.com 2003-10-23 10:02:29 MST ----

On what method? On Convert?



---- Additional Comments From gonzalo@ximian.com 2003-10-23 10:13:41 MST ----

YEs. It's now splitted in ConvertDate. The if (match.Success && order
== "ymd" is not an ||.



---- Additional Comments From yaronsh@mainsoft.com 2003-10-23 10:19:08 MST ----

At both old and new versions the condition is 
if(matchDate.Success && order == "ymd")

Are you sure it's in the cvs?

Imported an attachment (id=165088)