Sub Activity_Create(FirstTime As Boolean)
If FirstTime Then
' FTP.Initialize("FTP", "ftp.temasis.com.ar", 21, "ftpsarly", "cacota")
FTP.Initialize("FTP", "127.0.0.1", 21, "namehere", "passwordhere")
End If
Activity.LoadLayout("Main")
End Sub
Sub Button1_Click
' FTP.DownloadFile("Team/prestadores.txt", False, File.DirRootExternal, "PRESTATUTI.txt")
FTP.DownloadFile("Export/AR1_Base.tab" , False, File.DirRootExternal, "My_Base.tab")
End Sub
Sub FTP_DownloadProgress (ServerPath As String, TotalDownloaded As Long, Total As Long)
Dim s As String
s = "Downloaded " & Round(TotalDownloaded / 1000) & "KB"
If Total > 0 Then s = s & " out of " & Round(Total / 1000) & "KB"
Log(s)
End Sub
Sub FTP_DownloadCompleted (ServerPath As String, Success As Boolean)
' Log(ServerPath & ", Success=" & Success)
' If Success = False Then Log(LastException.Message)
Msgbox(ServerPath,"")
If Success = False Then Msgbox(LastException.Message,"")
End Sub