Home > Back-end >  How to EDIT the path of the store to open a picture
How to EDIT the path of the store to open a picture

Time:11-11

For example, the input in EDIT1 is C: \ 001. JPG

I want to click on the button, open the file, not open in DELPHI, but by the default WINDOWS open,

CodePudding user response:

refer to the original poster NEEZA which zha response:
, for example in EDIT1 input is C: \ 001. JPG

I want to click on the button, open the file, not open in DELPHI, but by the default WINDOWS open,


 
USES the
SHELLAPI;

Procedure TForm8. Button1Click (Sender: TObject);
The begin
ShellExecute (handle, the 'open', PWideChar (Edit1. Text), "', ' ', SW_SHOWNORMAL);
end;

  • Related