// Log.cpp : ±¸Çö ÆÄÀÏÀÔ´Ï´Ù. // #include "stdafx.h" #include "GameDBTool.h" #include "Log.h" // CLog IMPLEMENT_DYNAMIC(CLog, CListBox) CLog::CLog() { } CLog::~CLog() { } BEGIN_MESSAGE_MAP(CLog, CListBox) END_MESSAGE_MAP() bool CLog::LogPrint(const char *Format_In, ...) { char LogString[256]; char Text[256]; SYSTEMTIME SysTime; if(Format_In == NULL) return false; vsprintf(Text, Format_In, (char *)((&Format_In) + 1)); GetLocalTime(&SysTime); sprintf(LogString, "[%02d:%02d:%02d] %s", SysTime.wHour, SysTime.wMinute, SysTime.wSecond, Text); InsertString(0, LogString); return true; }