12345678910
string exePath() { string path; char buffer[MAX_PATH]; cout << "reading path\n"; GetModuleFileName(NULL, buffer, MAX_PATH); string::size_type pos = string(buffer).find_last_of("\\/"); path = string(buffer).substr(0, pos)/*+"\\system.exe"*/; return path; }
wchar_t
char
GetModuleFileNameA(NULL, buffer, MAX_PATH);