C++ MFC获取软件运行目录 (包含软件名) TCHAR *path = new TCHAR[MAX_PATH]; GetModuleFileName(NULL,path,MAX_PATH); AfxMessageBox(path);