private TIME_FIELDS SYSTEMTIME_To_TIME_FIELDS(_SYSTEMTIME st) { return(new TIME_FIELDS { Year = st.wYear, Month = st.wMonth, Day = st.wDay, Hour = st.wHour, Minute = st.wMinute, Second = st.wSecond, Milliseconds = st.wMilliseconds, Weekday = st.wDayOfWeek }); }
private _SYSTEMTIME createSystemTime(DateTime dateTime) { var systemTime = new _SYSTEMTIME() { wYear = (ushort)dateTime.Year, wMonth = (ushort)dateTime.Month, wDay = (ushort)dateTime.Day, wHour = (ushort)dateTime.Hour, wMinute = (ushort)dateTime.Minute, wSecond = (ushort)dateTime.Second, wMilliseconds = (ushort)dateTime.Millisecond, }; return(systemTime); }
public static extern bool FileTimeToSystemTime(ref _FILETIME lpFileTime, out _SYSTEMTIME lpSystemTime);
public static extern Boolean FileTimeToSystemTime([In] ref System.Runtime.InteropServices.ComTypes.FILETIME lpFileTime, out _SYSTEMTIME lpSystemTime);