[Mono-bugs] [Bug 60912][Nor] Changed - DateTime.Parse() does not support pattern "6/28/2004 12:00:00 AM"

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Wed, 30 Jun 2004 03:23:35 -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 ianm@activestate.com.

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

--- shadow/60912	2004-06-30 01:02:01.000000000 -0400
+++ shadow/60912.tmp.12043	2004-06-30 03:23:35.000000000 -0400
@@ -65,6 +65,19 @@
 Oops, please ignore  
 
 ------- Additional Comments From rshade@dvsconsulting.com  2004-06-30 01:02 -------
 My default culture seems to be the invariant culture.
 
 This test fails for all cultures for me.
+
+------- Additional Comments From ianm@activestate.com  2004-06-30 03:23 -------
+Whats also a major problem is that the result of ToString() on a
+DateTime object instance is in the above format and so the following
+code fails:
+     DateTime newDate = DateTime.Parse("01/01/1980");
+     DateTime secondDate = new DateTime();
+     string dateText=newDate.ToString(); // creates the string 
+1/1/1980 12:00:00 AM
+     Console.WriteLine("string ver is {0}", dateText);
+     secondDate = DateTime.Parse(dateText,CultureInfo.InvariantCulture);
+
+