<<

Contents

Search

>>

 

FILEDIALOG_CLIENT

 

 

Instruction

 

 

Syntax:

FILEDIALOG_CLIENT(<Header>,<Filter>,<Default Directory>,<Default Filename>,<Default Extension>[,<Filter Index>[,<Multiple Selection>,<Separator>,<Save>,<Standard Dialog>]])

 

<Header>

= <STRING-EXPRESSION>

<Filter>

= <STRING-EXPRESSION>

<Default Directory>

= <STRING-EXPRESSION>

<Default Filename>

= <STRING-EXPRESSION>

<Default Extension>

= <STRING-EXPRESSION>

<Filter Index>

= <NUM-EXPRESSION>

<Multiple Selection>

= <NUM-EXPRESSION>

<Separator>

= <STRING-EXPRESSION>

<Save>

= <NUM-EXPRESSION>

<Standard Dialog>

= <NUM-EXPRESSION>

 

 

Meaning:

Calls the standard file dialog on the client for selection of a file or a directory.

 

If the program is not a Java-2T-program, FILEDIALOG_CLIENT is identical with FILEDIALOG.

 

Attention: In Html programs only the filename is returned. Because of security reasons the filepath is not availabe. Some browsers return the filename with a pseudo path.

 

After the dialog has been closed EBUS_DATA contains the status and EBUS_DATA$ contains the selected file-/ directory name.

 

Value of EBUS_DATA

Meaning

0

The dialog has been cancelled.

1

EBUS_DATA$ contains the selected file-/ directory name.

-1

Runtime error

 

Parameter:

Header

Specifies the header of the dialog.

 

Filter

Pairs of strings must be specified respectively, the separator is "|".

Example: "Programs|*.exe|All Files|*.*". In the dialog box the filters are then displayed with File Type as shown below:

Programs (*.exe)

All files (*.*)

 

If <FILTER> = "", only a directory but no file can be selected.

 

Default Directory

Specifies the default directory. If the empty string "" is put in, the current directory is set.

 

Default Filename

Specifies the default setting in the field Filename .

 

Default Extension

Specifies the file name extension, which is automatically added to the filename if a filename is entered without extension.

 

Filter Index

Defines which <Filter> pair is used as default setting in the dialog.

Multiple Selection

0: Only one file can be selected.

<> 0: Several files can be selected. The single filenames are separated by the first character of <Separator>. If this parameter is missing or if <Separator> is the empty string "", the semi-colon ";" is used as separator.

 

Multiple selection is not possible with directories, only with files.

 

Separator

Specifies the separator by which several selected files are separated.

 

Save

0: The Select button has the text 'Open'.

<> 0: The Select button has the text 'Save'.

If this parameter is missing, then this is equivalent to 0.

 

Standard Dialog

<> 0: The Java standard dialog is displayed.

0: A dialog created by EBUS-J is displayed. 

With the EBUS-J-Dialog the program remembers the size and the directory that was used last. Moreover the number of files in the directory is shown. In the 2T-program the EBUS-J-Dialog is always opened since the Java file dialog cannot display files from the Server.

 

The absence of this parameter is equivalent to 0.

 

Sample:

FILEDIALOG_CLIENT("Select file" ,

                  "Programs|*.exe|Images|*.gif;*.png;*.jpg|All files|*.*",

                  "" , "" , "" , 2 , 0 , "" , 0 , 1)

IF EBUS_DATA = 1

THEN FILE$ = EBUS_DATA$

ENDIF

 

See also:

FILEDIALOG

EBUS_DATA

EBUS_DATA$