what is invariantculture c# code example

what is invariantculture c#

1

1 Example

0
var d = DateTime.Now;
var s1 = d.ToString(CultureInfo.InvariantCulture);   // "05/21/2014 22:09:28"
var s2 = d.ToString(new CultureInfo("en-US"));       // "5/21/2014 10:09:28 PM"
by on

Other Code Examples