Copy link to clipboard
Copied
Hello everyone. Tell me how I can implement a button to open the browser and select a file. And then write a link to that file in a variable. Or can this be done with a plugin?
i solved the problem.
For open dialog browser for choose file
File().openDlg;
for open dialog browser for choose folder
Folder().selectDlg;
Copy link to clipboard
Copied
i solved the problem.
For open dialog browser for choose file
File().openDlg;
for open dialog browser for choose folder
Folder().selectDlg;
Copy link to clipboard
Copied
Usually, you should use File().openDlg only if you want to preselect a particular file by default and use
File.openDialog( [prompt, filter, multiSelect] )
otherwise:
new File("~/Desktop/test.mp4").openDlg("Please choose a video file"); // this preselects test.mp4 on my desktop
File.openDialog("Please choose a video file"); // this opens the default location and preselects no file
(note the difference between Dialog and Dlg)