<<

Contents

Search

>>

 

FTP_PUTFILE

 

 

Function

 

 

Syntax:

FTP_PUTFILE(<Host>,<Host Filename>,<Username>,<Password>,<Client Filename>,<Progressbar>)

 

<Host>

= <STRING-EXPRESSION>

<Host Filename>

= <STRING-EXPRESSION>

<Username>

= <STRING-EXPRESSION>

<Password>

= <STRING-EXPRESSION>

<Client Filename>

= <STRING-EXPRESSION>

<Progressbar>

= <STRING-EXPRESSION>

 

 

Meaning:

Copies files from the client to the FTP server.

 

<Host Filename> and <Client Filename> can contain several filenames separated by semi-colon.

 

FTP_PUTFILE saves the file <Client Filename> on the Server <Host> under the name <Host Filename>.

 

There must be an Internet connection.

 

FTP_PUTFILE returns the result 0, if no error occurred, otherwise an error number. In the case of an error ERRORTEXT$ contains the error report.

 

Parameter:

Host

Name of FTP server

Host Filename

Name of  host file. The name must contain a full path. Several filenames can be specified separated by semi-colons.

Username

Username for access to <Host>

Password

Password for access to <Host>

Client Filename

Name of client file. Several filenames can be specified separated by semi-colons.

Progressbar

Contains, separated by ';' , the following parameters of the instruction PROGRESSBAR:

 

        <Row>;<Column>;<Length>;<Color1>;<Color2>

 

If at least the parameters <Row>, <Column> and <Length> are specified, a bar shows the work progress just like with the instruction PROGRESSBAR. 

 

 

Sample:

HOST$ = "www.xxx.de"

HOST_FILE$ = "/index.html;/search.html"

CLIENT_FILE$ = "C:\tmp\index.html;C:\tmp\search.html"

USERNAME$ = "user1"

PASSWORT$ = "passwort1"

 

H% = FTP_PUTFILE(HOST$,HOST_FILE$,USERNAME$,PASSWORT$,

                 CLIENT_FILE$,“7;10;40“)

IF H% <> 0

THEN ERRORMES = "Error" + STR$(H%) + " " + ERRORTEXT$

ENDIF

 

See also:

FTP_DELETEFILE

FTP_GETFILE

FTP_GETFILEINFO$

PROGRESSBAR