[Mono-bugs] [Bug 56123][Maj] Changed - Now.Date isn't returning the correct value
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Sun, 28 Mar 2004 14:22:01 -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 rafaelteixeirabr@hotmail.com.
http://bugzilla.ximian.com/show_bug.cgi?id=56123
--- shadow/56123 2004-03-27 18:32:02.000000000 -0500
+++ shadow/56123.tmp.18495 2004-03-28 14:22:01.000000000 -0500
@@ -1,14 +1,14 @@
Bug#: 56123
Product: Mono: Class Libraries
Version: unspecified
OS: All
OS Details:
-Status: NEW
-Resolution:
-Severity:
+Status: RESOLVED
+Resolution: NOTABUG
+Severity: Unknown
Priority: Major
Component: CORLIB
AssignedTo: mono-bugs@ximian.com
ReportedBy: alexmipego@hotmail.com
QAContact: mono-bugs@ximian.com
TargetMilestone: ---
@@ -18,6 +18,19 @@
making a Response.Write(DateTime.Now.Date); is returning this:
'3/27/04 12:00:00a'
The date is correct but the time isn't, and the time shouldn't be there.
+
+------- Additional Comments From rafaelteixeirabr@hotmail.com 2004-03-28 14:22 -------
+A DateTime struct always contains the Time-part, but it is zeroed to
+midnight when using it to represent a Date (there isn't a Date type),
+in the class documentation the Date property is documented as:
+
+public DateTime Date { get; }
+
+That's why you are seeing '3/27/04 12:00:00a'. If you want to have
+only the Date-part printed, you have to format aproprietaly. something
+like:
+
+Response.Write(DateTime.Now.Date.ToString("d"))