//获取当前程序的运行目录
#include <Windows.h>
string GetAppPathA()
{
char szExePath[MAX_PATH] = {0};
GetModuleFileNameA(NULL,szExePath,MAX_PATH);
char *pstr = strrchr(szExePath,'\\');
memset(pstr+1,0,1);
string strAppPath(szExePath);
return strAppPath;
}
string strLogPath = GetAppPathA().append("LogInfo\\");
CreateDirectoryA(strLogPath.c_str(),NULL);