Hi people from B4X, I'm testing B4J, and I need to download some files.
I like to save it on the same location my app is running.
But at the moment I can download, but I dont know where is the file downloaded.
I like to save it on the same location my app is running.
But at the moment I can download, but I dont know where is the file downloaded.
B4X:
Sub JobStart
Dim job1 As HttpJob
Log("Job Init...")
job1.Initialize("Job1", Me)
Log("Jobname: " & job1.JobName)
'Send the version file
Log("Job download start...")
Dim url As String = "https://www.download.com/tool.zip"
job1.Download(url)
Log("Job download start completed...")
End Sub
Sub JobDone (Job As HttpJob)
Log("JobName = " & Job.JobName & ", Success = " & Job.Success)
If Job.Success = True Then
Select Job.JobName
Case "Job1"
'print the result to the logs
Log(Job.GetString)
End Select
Else
Log("Error: " & Job.ErrorMessage)
End If
Job.Release
Dim msgbox As Msgboxes
msgbox.Show("Descargado","")
End Sub