http://topic.csdn.net/t/20010620/20/165899.html
1楼 iProgram ( Concorde Jet) 回复于 2001-06-20 20:47:00 得分 20
1楼 iProgram ( Concorde Jet) 回复于 2001-06-20 20:47:00 得分 20
#include <direct.h>
#include <shlobj.h>
//Code
BROWSEINFO bi ={0};
char pszDisplayName[MAX_PATH] ="\0";
bi.pszDisplayName = pszDisplayName;
bi.lpszTitle="Select a folder:";
bi.hwndOwner=m_hWnd;
bi.ulFlags=BIF_DONTGOBELOWDOMAIN|BIF_RETURNONLYFSDIRS;
LPITEMIDLIST lpIL = SHBrowseForFolder(&bi);
if(lpIL)
{
SHGetPathFromIDList(lpIL,bi.pszDisplayName);
MessageBox(bi.pszDisplayName);//Drv Here
}