Application.getopenfilename (FileFilter, FileIndex, Fileselecttitle, button, False)
FileFilter: Specifies the type of file that can be selected
Example: "csv file (*.csv), *.csv, All Files (*. *), *. *"
One thing to note here is that if there are n pairs, the return value of the program is an array when n>1, and if n=1, the return value is a string.
FileIndex: Specifies the default file type,
Example: 2 o'clock, then all file types are default values
Fileselecttitle: Specifies the title of the popup's File selection box
Button: It's said to be for Mac, no matter ....
The last value that specifies whether multiple selections are available, that is, you can select more than one file.
The return value of this program needs to be noted, if the file is selected, then there is no problem.
If you close the File Selection window without selecting a file, the return value is "False".
That's so damn weird!
VBA opens a file by file type name