셈말짓기/CTRL+C / CTRL+V
윈도우 시간 로컬 문자열로 변환
셈말짓기
2012. 6. 14. 11:29
TCHAR text[128];
SYSTEMTIME st;
int result = 0;
GetLocalTime (&st);
result = GetDateFormat(LOCALE_USER_DEFAULT, DATE_SHORTDATE, &st, NULL, text, 128);
if (result)
{
// printf (text);
}
result = GetTimeFormat(LOCALE_USER_DEFAULT, /*LOCALE_NOUSEROVERRIDE*/0, &st, _T("HH:mm:ss"), text, 128);
if (result)
{
// printf (text);
}