fileselector class : Select() method

Description

Opens a dialog.

Syntax

instance.Select()

Arguments

None.

Return value

ClassDescription
pairSelection result.

Sample code

1:

fileselector fsel = new fileselector();

2:

pair resuilt = fsel.Select();

3:

if(result.First)

4:

string filePath = result.Second;

5:

endif

Notes

The dialog will be open in the directory where the last file was selected.


The selection result is returned as the pair class.

First: Whether a file is selected is stored as a bool class.

True if a file is selected. Otherwise it is false.

Second: It is stored the path of the selected file as the string. If no file is selected, it is an empty string.

Links for reference

None.

Copyright © Cooker All rights reserved.