?? debugerror.cpp
字號:
#include "stdafx.h"
#include "DebugError.h"
#ifdef __DEBUG__
#include <stdio.h>
#include <string.h>
#include <time.h>
void OutputLogToFile( const char* str )
{
if( str )
{
FILE* pFile = fopen( DEBUG_LOG_FILE, "a" );
if( pFile )
{
fprintf( pFile, "\0\r" );
fprintf( pFile, str );
fclose( pFile );
}
}
}
void OutputLogToFile1( const char* str, int val )
{
if( str )
{
int nlength = (int)strlen( str );
char *p = new char[nlength + 32];
sprintf( p, str, val );
OutputLogToFile( p );
delete p;
}
}
void OutputTimeToFile()
{
//char ch[128];
//struct tm *newtime;
//time_t aclock;
//time( &aclock );
//newtime = localtime( &aclock );
//sprintf( ch, "Time:%-2d.%-2d:%-2d:%-2d\t", newtime->tm_mday, newtime->tm_hour, newtime->tm_min, newtime->tm_sec );
//OutputDebugLog( ch );
}
#endif // __DEBUG__
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -