Showing the properties of a file
Top  Previous  Next


To show the file property dialog commonly used in Windows, call the ShowFileProperties() procedure below passing a filename:

uses ShellAPI;

procedure ShowFileProperties(const FileName: string);
{ Displays the Properties dialog for a file or directory. }
{ Thanks to Peter Below (TeamB) <100113.1101@compuserve.com> }
{ for this code. }
var
  sei: TShellExecuteInfo;
begin
  FillChar(sei, SizeOf(sei), 0);
  sei.cbSize := SizeOf(sei);
  sei.lpFile := PChar(FileName);
  sei.lpVerb := 'properties';
  sei.fMask := SEE_MASK_INVOKEIDLIST;
  ShellExecuteEx(@sei);
end;


Blue Orb Software
support@blueorbsoft.com