/// <summary> /// Converts a SystemTime structure to a System.DateTime structure /// </summary> /// <param name="time">The SystemTime structure to be converted</param> /// <returns>A System.DateTime structure that was created based on /// the value of the SystemTime structure.</returns> public static DateTime ToDateTime(SystemTime time){ //construct a DateTime object from the SystemTime object that was passed in return new DateTime(time.Year, time.Month, time.Day, time.Hour, time.Minute, time.Second, time.Millisecond); }
internal static extern void GetSystemTime(out SystemTime localTime);