Skip to content

Instantly share code, notes, and snippets.

@jacking75
Created April 18, 2012 15:45
Show Gist options
  • Save jacking75/2414449 to your computer and use it in GitHub Desktop.
Save jacking75/2414449 to your computer and use it in GitHub Desktop.
localtime에서 초 단위의 시간으로 변환
struct tm timeinfo;
memset( &timeinfo, 0, sizeof(timeinfo) );
timeinfo.tm_year = atoi( szYear ) - 1900;
timeinfo.tm_mon = atoi( szMonth ) - 1;
timeinfo.tm_mday = atoi( szDay );
DWORD nSecondTime = static_cast<DWORD>(mktime( &timeinfo ));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment