Share via


CTime::GetTime

Returns a __time64_t value for the given CTime object.

__time64_t GetTime( ) const throw( );

Return Value

GetTime will return the number of seconds between the current CTime object and January 1, 1970.

Example

CTime t(2005, 10, 20, 23, 50, 0); // 11:50 PM October 20, 2005
time_t osBinaryTime = t.GetTime();  // time_t defined in <time.h>

_tprintf_s(_T("time_t = %ld\n"), osBinaryTime);

Requirements

Header: atltime.h

See Also

Reference

CTime Class

Hierarchy Chart

CTime::CTime

Other Resources

CTime Members