string foo = yourDateTime.ToUniversalTime()
.ToString("yyyy'-'MM'-'dd'T'HH':'mm':'ss'.'fff'Z'");
More Related Contents:
- Convert UTC/GMT time to local time
- How does DateTime.ToUniversalTime() work?
- DateTime.Parse(“2012-09-30T23:00:00.0000000Z”) always converts to DateTimeKind.Local
- How do I calculate someone’s age based on a DateTime type birthday?
- Parse DateTime with time zone of form PST/CEST/UTC/etc
- String was not recognized as a valid DateTime ” format dd/MM/yyyy”
- C# DateTime.Now precision
- format date in c#
- How do I get the last day of a month?
- What does “DateTime?” mean in C#?
- Get Month name from month number
- Environment.TickCount vs DateTime.Now
- How do I represent a time only value in .NET?
- Why DateTime.AddHours doesn’t seem to work?
- How to convert Javascript datetime to C# datetime?
- How to find the 3rd Friday in a month with C#?
- Globally convert UTC DateTimes to user specified local DateTimes
- DateTime ToString issue with formatting months with “mm” specifier
- why does DateTime.ToString(“dd/MM/yyyy”) give me dd-MM-yyyy?
- How to ensure a timestamp is always unique?
- How frequent is DateTime.Now updated ? or is there a more precise API to get the current time?
- Convert String to Date in .NET if my incoming date format is in YYYYMMDD
- How to parse and generate DateTime objects in ISO 8601 format
- DateTime conversion from string C#
- Getting the first and last day of a month, using a given DateTime object
- Days, hours, minutes, seconds between two dates
- How to check if a DateTime occurs today?
- Convert DateTime to long and also the other way around
- LINQ Query to Convert string to datetime
- .NET DateTime to SqlDateTime Conversion