Transfer Engine (SDK)
If MySite.AsyncTaskNumber > 10 then
MsgBox "Aborting 11th task"
MySite.AbortAsync ( 10 )
abort task # 11 (one less then
total, since
starts from 0)
End if
Note:
You must set
MySite.Option("CleanupAsync") = False
so that all asynchronous tasks are counted. Otherwise, only the last
asynchronous task launched will be referenced when calling the
AbortAsync method.
Automatically encrypting and compressing transfers
To automatically encrypt and compress files before transfer, you will need both CuteZIP and
CuteFTP Professional. You can also compress and encrypt files after transferring them by
using GlobalSCAPE Secure FTP Server s Custom Site Commands. The benefits of
encrypting files prior or post transfer depends on the circumstances and level of trust for the
particular host.
In the example script below, an entire folder (including sub folders) is compressed,
encrypted (using Twofish 128 bit encryption) and then transferred via regular FTP to an
FTP server. Since the archived file is encrypted, there is no need to connect using SSL, OTP,
or SSH2 unless you wished to also protect the login process.
Example
Dim WshShell, MySite, Return
Set WshShell = CreateObject("WScript.Shell") Window s
Scripting Host shell object
next line calls the run method of the WSH shell object.
It returns true once CuteZIP does its thing.
The complete command line instructions for CuteZIP are
located here.
If Return = WshShell.run
("c:\progra~1\global~1\CuteZIP\cutezip.exe c p12345
c:\archive c:\temp", 0, true) Then
Set MySite = CreateObject("CuteFTPPro.TEConnection")
MySite.Option ("ThrowError") = True
MySite.Host = "ftp://user:pass@myftpsite.com" one of
the ways to connect using the TE
MySite.Connect
201
footer
Our partners:
PHP: Hypertext Preprocessor Best Web Hosting
Java Web Hosting
Inexpensive Web Hosting
Jsp Web Hosting
Cheapest Web Hosting
Jsp Hosting
Cheap Hosting
Visionwebhosting.net Business web hosting division of Web
Design Plus. All rights reserved