Hi all,
the code below doesn't work
(RuntimeException) java.lang.RuntimeException: Object should first be initialized (List).
What shoud I do?
Thanks
the code below doesn't work
(RuntimeException) java.lang.RuntimeException: Object should first be initialized (List).
What shoud I do?
Thanks
B4X:
Dim ftp As FTP
Sub StartFTP
ftp.Initialize("FTP", "server", 21, "user", "password")
ftp.PassiveMode = True
ftp.List("/")
end suib
Sub FTP_ListCompleted (ServerPath As String, Success As Boolean, Folders() As FTPEntry, Files() As FTPEntry)
Log(ServerPath)
If Success = False Then
Log(LastException)
Else
For i = 0 To Folders.Length - 1
Log(Folders(i).Name)
Next
For i = 0 To Files.Length - 1
Log(Files(i).Name & ", " & Files(i).Size & ", " & DateTime.Date(Files(i).Timestamp))
Next
End If
End Sub