Uploads or downloads a file through MobiLink.
mlfiletransfer [ options ] file
|-ap param1, ...||MobiLink authentication parameters. See Authentication parameters.|
|-g||Shows transfer progress.|
|-i||Ignore partial transfer from a previous attempt.|
|-k||Remote key to identify the remote. This is optional.|
|-lf filename||The local name of the file to be transferred. By default, the name as recognized by the server (i.e. file) is used.|
|-lp path||The local path for the file to be transferred. By default, the local path is the root directory on Windows Mobile, and the current directory on other platforms.|
|-p password||The password for the MobiLink user name.|
|-q||Quiet mode. Messages are not displayed.|
|-s||Upload a file to MobiLink. Download is the default.|
|-u username||MobiLink user name. This option is required.|
|-v version||The script version. This option is required.|
|-x protocol ( options )||
The protocol can be one of tcpip, tls, http, or https.This option is required.
The protocol-options you can use depend on the protocol. For a list of options for each protocol, see MobiLink client network protocol option summary.
The file to be transferred as named on the server. When downloading, MobiLink looks for the file in the username subdirectory of the -ftr directory; if it does not find it there, it looks in the -ftr directory. If the file is not in either place, MobiLink generates an error. See -ftr mlsrv12 option.
When uploading, MobiLink looks for the files in the directory specified with the -ftru mlsrv12 option. See -ftru mlsrv12 option.
This utility is useful for downloading files when you first create a remote database, when you need to upgrade software on your remote device, and so on.
To use this utility to download files, you must start the MobiLink server with the -ftr option. The -ftr option creates a root directory for the file to be transferred, and creates a subdirectory for every registered MobiLink user.
To use this utility to upload files, you must start the MobiLink server with the -ftru option. The -ftru option creates a location for files that are to be uploaded.
You can use mlagent as an alternative to mlfiletransfer. See Configuring and running the MobiLink Agent on the client device.
UltraLite users can also use the MLFileDownload and MLFileUpload methods in the UltraLite runtime. See Using MobiLink file transfers.
The following command connects the MobiLink server to the CustDB sample database. The
-ftr %SystemRoot%\system32 option tells the MobiLink server to start monitoring the Windows\system32 directory for requested files. In this example the MobiLink server first looks for the file in the C:\Windows\system32\mobilink-username directory. If the file does not exist, it looks in the C:\Windows\system32 directory. In general you would not want to have the MobiLink server monitor your Windows\system32 folder for files. This example uses the Windows\system32 directory so that it can transfer the Notepad utility, which is located there.
mlsrv12 -c "dsn=SQL Anywhere 12 CustDB" -zu+ -ftr %SystemRoot%\system32
The following command runs the mlfiletransfer utility. It causes the MobiLink server to download notepad.exe to your local directory.
MLFileTransfer -u 1 -v "custdb 12.0" -x tcpip notepad.exe
Discuter à propos de cette page dans DocCommentXchange.
|Copyright © 2010, iAnywhere Solutions, Inc. - SQL Anywhere 12.0.0|