Finding application path with Windows API?
Working on my game, obviously, but I'm not very familiar with the Windows API. Is there a function that is similar to using "App.Path" in VB that I can use for C++?
GetModuleFileName
TCHAR szPath[MAX_PATH]; if( !GetModuleFileName( NULL, szPath, MAX_PATH ) ) { printf("GetModuleFileName failed (%d)\n", GetLastError()); return FALSE; }
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement