|
1. Display the file properties dialog:
void CrnShowFileProp (char * szFileName)
{
SHELLEXECUTEINFO sei;
ZeroMemory (&sei, sizeof (sei));
sei.cbSize = sizeof (sei);
sei.lpFile = szFileName;
sei.lpVerb = "Properties";
sei.fMask = SEE_MASK_INVOKEIDLIST;
// Note here that lpFile must be assigned the corresponding file name, and lpVerb must be assigned the value "properties"
// fMask must be assigned the value SEE_MASK_INVOKEIDLIST.
// Next call the ShellExecuteEx API function:
ShellExecuteEx (&sei);
}
// Example of use:
CrnShowFileProp ("C:\\夜 云 男爵\\123.exe");
2. When using SHFileOperation to delete a file, a progress bar can be displayed. Do not specify the FOF_SILENT parameter. |
|