On Sep 22, 7:06*pm, PeteOlcott <PeteOlc...@gmail.comwrote:
Quote:
On Sep 22, 5:45*pm, "Mark Salsbery [MVP]"
>
<MarkSalsbery[MVP]@newsgroup.nospamwrote:
Quote:
Here's my source, BTW:
>
Quote:
Converting a time_t Value to a File Timehttp://msdn.microsoft.com/en-us/library/ms724228(VS.85).aspx
>
>
Quote:
--
Mark Salsbery
Microsoft MVP - Visual C++
>
Here is the answer that I derived:
>
System::DateTime time_tToSystemDateTime(time_t tt)
{
* tm* timeptr = gmtime(&tt);
* DateTime sdt(timeptr->tm_year + 1900, timeptr->tm_mon + 1, timeptr-
>
>
>
Quote:
tm_mday, timeptr->tm_hour, timeptr->tm_min, timeptr->tm_sec);
* return sdt;
}- Hide quoted text -
>
- Show quoted text -
Here it is again, (Hopefully with better formatting)
System::DateTime time_tToSystemDateTime(time_t tt)
{
tm* timeptr = gmtime(&tt);
DateTime sdt(timeptr->tm_year + 1900,
timeptr->tm_mon + 1,
timeptr->tm_mday,
timeptr->tm_hour,
timeptr->tm_min,
timeptr->tm_sec);
return sdt;
}