public static FILETIME ToFILETIME(this SYSTEMTIME st) { var ft = new FILETIME(); SystemTimeToFileTime(ref st, ref ft); return ft; }
public static extern bool FileTimeToSystemTime(ref FILETIME lpFileTime, ref SYSTEMTIME lpSystemTime);
public static SYSTEMTIME ToSYSTEMTIME(this FILETIME ft) { var st = new SYSTEMTIME(); FileTimeToSystemTime(ref ft, ref st); return st; }
public static extern bool TzSpecificLocalTimeToSystemTimeEx([In] ref DYNAMIC_TIME_ZONE_INFORMATION lpTimeZoneInformation, [In] ref SYSTEMTIME lpLocalTime, out SYSTEMTIME lpUniversalTime);
public static extern bool TzSpecificLocalTimeToSystemTime([In, MarshalAs(UnmanagedType.LPStruct)] TIME_ZONE_INFORMATION lpTimeZoneInformation, [In, MarshalAs(UnmanagedType.LPStruct)] SYSTEMTIME lpLocalTime, [Out] out SYSTEMTIME lpUniversalTime);
/// <summary>Convert a <see cref="SYSTEMTIME"/> value to a <see cref="FILETIME"/> value.</summary> /// <param name="st">The <see cref="SYSTEMTIME"/> value.</param> /// <returns>The converted <see cref="FILETIME"/> value.</returns> public static FILETIME ToFILETIME(this SYSTEMTIME st) { SystemTimeToFileTime(st, out var ft); return(ft); }
public static extern int GetDateFormat(uint Locale, DATE_FORMAT dwFlags, [In] ref SYSTEMTIME lpDate, [In] string lpFormat, [Out] StringBuilder lpDateStr, int cchDate);
public static extern int GetTimeFormatEx(string lpLocaleName, TIME_FORMAT dwFlags, [In] ref SYSTEMTIME lpTime, [In] string lpFormat, [Out] StringBuilder lpTimeStr, int cchTime);