Mirror

Show the property dialog for a file (Views: 713)


Problem/Question/Abstract:

How can I show the property dialog for a file?

Answer:

procedure ShowPropertiesDialog(Filename: string);
var
  SEI: TShellExecuteInfo;
begin
  FillChar(SEI, SizeOf(SEI), 0);
  with SEI do
  begin
    cbSize := SizeOf(SEI);
    lpFile := PChar(Filename);
    lpVerb := 'properties';
    fMask := SEE_MASK_INVOKEIDLIST;
  end;
  ShellExecuteEx(@SEI);
end;

<< Back to main page