how to setup FTP connection / signal when FTP server is not active in FTP Client?
because in my code below, the process timed out for a very long time.
is that adjustable too?
because in my code below, the process timed out for a very long time.
is that adjustable too?
My Code:
Private Sub B4XPage_Appear
'
ftp.Initialize("FTP", "192.168.1.100", "51041", "myuser", "mypassword")
ftp.PassiveMode = True
'
Go_Download
'
End Sub
Sub Go_Download
PD.MyProgressDialogShow("Download File", "Please Wait...")
'
Dim strFile As String = "myfile.txt"
Dim sf As Object
sf = ftp.DownloadFile("download/" & strFile, False, xui.DefaultFolder, strFile)
Wait For (sf) FTP_DownloadCompleted (ServerPath As String, Success As Boolean)
If Success Then
TM.MyToastMsg("Finish...")
PD.MyProgressDialogHide
Else
TM.MyToastMsg("Error...")
PD.MyProgressDialogHide
End If
End Sub