Skip to content

Instantly share code, notes, and snippets.

using System;
using System.Threading;
namespace ConsoleApplication3 {
class Program {
static void Main(string[] args) {
Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("en-US");
Thread.CurrentThread.CurrentTimeZone = TimeZoneInfo.FindSystemTimeZoneById("Mountain Standard Time");
DateTime postedDk = new DateTime(2016, 12, 17, 6, 28, 0, DateTimeKind.Local);
using System;
using System.Threading;
namespace ConsoleApplication3 {
class Program {
static void Main(string[] args) {
Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("en-US");
DateTime postedDk = new DateTime(2016, 12, 17, 6, 28, 0, DateTimeKind.Local);
DateTime postedUtc = TimeZoneInfo.ConvertTime(postedDk, TimeZoneInfo.Local, TimeZoneInfo.Utc);