Hello Erel, I need help, i'm working on this app which up until now everything works great, thanks to this great httputil class.
However when i send this request
I get no error but i get nothing when i try to read with textreader.
I checked the file that gets saved to the SD card and in fact it is empty, i have been trying to figure out all day but i've had no luck, however when i send this other request
and then check the file saved in the sd card i do see the html data.
Can you help me figure this out, when i copy and paste both urls to my browser i can see they both work, but i can't figure out why the first url does not return any information.
Here's the jobdone code
queryresult = "https://thepiratebay.se/search/Batman/0/99/0"
job4.Initialize("Query_Result", Me)
job4.Download(queryresult)
Sub JobDone(Job As HttpJob)
Select Job.JobName
Case "Main page"
HandleMainPage(Job)
Case "ImageJob"
ImagesJobDone(Job)
Case "Query_Result"
QueryResults(Job)
End Select
Job.Release
End Sub
Sub QueryResults (Job As HttpJob)
If Job.Success = True Then
Log("job4 was succesful")
End If
Dim line3 As String
Dim TextReader3 As TextReader
TextReader3.Initialize(Job.GetInputStream)
Do While line3 <> Null
line3 = TextReader3.ReadLine
ToastMessageShow("read line: " & line3, True)
Loop
End Sub
Your help will be greatly appreciated Erel.
Cheers,
Walter