Ejemplo n.º 1
0
 public static FILETIME ToFILETIME(this SYSTEMTIME st)
 {
     var ft = new FILETIME();
     SystemTimeToFileTime(ref st, ref ft);
     return ft;
 }
Ejemplo n.º 2
0
 public static extern bool FileTimeToSystemTime(ref FILETIME lpFileTime, ref SYSTEMTIME lpSystemTime);
Ejemplo n.º 3
0
 public static SYSTEMTIME ToSYSTEMTIME(this FILETIME ft)
 {
     var st = new SYSTEMTIME();
     FileTimeToSystemTime(ref ft, ref st);
     return st;
 }
Ejemplo n.º 4
0
 public static extern bool TzSpecificLocalTimeToSystemTimeEx([In] ref DYNAMIC_TIME_ZONE_INFORMATION lpTimeZoneInformation, [In] ref SYSTEMTIME lpLocalTime, out SYSTEMTIME lpUniversalTime);
Ejemplo n.º 5
0
 public static extern bool TzSpecificLocalTimeToSystemTime([In, MarshalAs(UnmanagedType.LPStruct)] TIME_ZONE_INFORMATION lpTimeZoneInformation, [In, MarshalAs(UnmanagedType.LPStruct)] SYSTEMTIME lpLocalTime, [Out] out SYSTEMTIME lpUniversalTime);
Ejemplo n.º 6
0
 /// <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);
 }
Ejemplo n.º 7
0
 public static extern int GetDateFormat(uint Locale, DATE_FORMAT dwFlags, [In] ref SYSTEMTIME lpDate, [In] string lpFormat, [Out] StringBuilder lpDateStr, int cchDate);
Ejemplo n.º 8
0
 public static extern int GetTimeFormatEx(string lpLocaleName, TIME_FORMAT dwFlags, [In] ref SYSTEMTIME lpTime, [In] string lpFormat, [Out] StringBuilder lpTimeStr, int cchTime);