In the Browse folder generated by "browseinfo" dialog box, no project named "create folder" is found. In my Program , create a folder and save it to the created folder. Of course, you can also create a directory in the specified directory and select from here. After all, you have to return the drive letter to the folder where you want to create the folder. It is convenient to create a folder at any time, as shown in the SAVE folder. As a result, the following Code can be used for personal needs:
# define bif_newdialogstyle 0x0040
# define bif_usenewui (bif_newdialogstyle | bif_editbox)
void selectfolder (hwnd, cstring & strselectpath)
{< br> browseinfo Bi;
char filename [max_path];
zeromemory (& BI, sizeof (browseinfo ));
bi. hwndowner = hwnd;
bi. pszdisplayname = filename;
bi. lpsztitle = "select folder";
bi. ulflags = bif_usenewui;
lpitemidlist IDL = shbrowseforfolder (& BI);
If (IDL = NULL)
return;
shgetpathfromidlist (IDL, filename);
}
here is the option to add new Folder:
# define bif_usenewui (bif_newdialogstyle | bif_editbox)
originally, only bif_newdialogstyle was used, and a macro can be defined, put the bifeditbox and above on OK. Try it on your own.