GetCurrentDirectory()
或用CFileFind中的GetFilePath()

解决方案 »

  1.   

    GetCurrentDirectory()
    或用CFileFind中的GetFilePath()
    还有其它的方法
      

  2.   

    #define MAX_STR 200
    #define MAX_LEN 200...
    char str[MAX_STR];
    GetModuleFileName(NULL,str,MAX_LEN);str中存放的就是当前程序的整个路径,包括文件自身的名称。
      

  3.   

    CString strExePath = "";TCHAR tchExeFile[MAX_PATH];
    ::memset(tchExeFile,0,sizeof(TCHAR) * MAX_PATH );
    ::GetModuleFileName(NULL,tchExeFile,MAX_PATH);strExePath = tchExeFile;
    strExePath = strExePath.Left(strExePath.ReverseFind('\\'));
      

  4.   

    同意楼上的,用  GetModuleFileName()好。