Android Question error in FTP pl help

manuaaa

Member
Licensed User
Longtime User
while using FTP i am getting this message, it was fine since last week suddenly start getting this message
my code is

Sub Activity_Create(FirstTime As Boolean)
If FirstTime Then
FTP.Initialize("FTP", "ftp.MANWIN.IN", 21, "usernmae", "password")
End If
Activity.LoadLayout("Main")
End Sub

Sub Button2_Click
FTP.UploadFile(File.DirRootExternal, "277377.jpg", True, "/AMMA/27377.jpg")
End Sub

Sub FTP_UploadProgress (ServerPath As String, TotalUploaded As Long, Total As Long)
Dim s As String
s = "Uploaded " & Round(TotalUploaded / 1000) & "KB"
If Total > 0 Then s = s & " out of " & Round(Total / 1000) & "KB"
Log(s)
End Sub

Sub FTP_UploadCompleted (ServerPath As String, Success As Boolean)
Log(ServerPath & ", Success=" & Success)
If Success = False Then Log(LastException.Message)
End Sub

Logs:

/AMMA/27377.jpg, Success=false
android.system.GaiException: android_getaddrinfo failed: EAI_NODATA (No address associated with hostname)


Please help

Thanks & regards,

Manoj
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Please use [code]code here...[/code] tags when posting code.

Seems like your server DNS is not configured properly.
SS-2016-02-04_09.40.47.png


You can use your server ip address instead.
 
Upvote 0

lemonisdead

Well-Known Member
Licensed User
Longtime User
B4X:
Sub Activity_Create(FirstTime As Boolean)
If FirstTime Then
FTP.Initialize("FTP", "ftp.MANWIN.IN", 21, "usernmae", "password")
End If
Activity.LoadLayout("Main")
End Sub

Sub Button2_Click
FTP.UploadFile(File.DirRootExternal, "277377.jpg", True, "/AMMA/27377.jpg")
End Sub

Sub FTP_UploadProgress (ServerPath As String, TotalUploaded As Long, Total As Long)
Dim s As String
s = "Uploaded " & Round(TotalUploaded / 1000) & "KB"
If Total > 0 Then s = s & " out of " & Round(Total / 1000) & "KB"
Log(s)
End Sub

Sub FTP_UploadCompleted (ServerPath As String, Success As Boolean)
Log(ServerPath & ", Success=" & Success)
If Success = False Then Log(LastException.Message)
End Sub
while using FTP i am getting this message, it was fine since last week suddenly start getting this message
The error message is explicit : no hostname found. Check your DNS settings :
  • ftp.manwin.in can not be found
  • pinging manwin.in has 100% packets lost
 
Upvote 0
Top