【お知らせ】この部分は英語原文のみでの提供となります。何卒ご了承ください。
2.1.27.1 BrowseForFolder
Contents
Description
Open an FDLog Browse (OpenPath) dialog box with showfiles option.
Syntax
bool BrowseForFolder( string * pstrPath, HWND hWndParent, LPCSTR lpcszTitle, DWORD dwCntrl )
Parameters
- pstrPath
- [input/output]Initial path when dialog opens, and get the selected folder's path
- hWndParent
- [input]Parent window. If NULL, Origin main window will be used
- lpcszTitle
- [input]Title of the dialog box, if NULL uses "Browse Folders"
- dwCntrl
- [input]if set BROWSEFOLDER_SHOW_FILES, it will display files under each folder
Return
true if a folder is selected, false if click Cancel button or double click on a file
Examples
EX1
void BrowseForFolder_ex() { string strPath = GetAppPath(); if( BrowseForFolder(&strPath, NULL, NULL, BROWSEFOLDER_SHOW_FILES) ) out_str(strPath); else out_str("please select a folder"); }
Remark
See Also
Header to Include
origin.h