I always get a message "Cannot POST /" when i running following code job1.PostString(link,"").
link --> http://192.168.1.110:8080
B4X:
Sub run
Dim job1 As HttpJob
Try
job1.Initialize("run",Me)
Dim link As String="http://"&Hostip&":"&Hostport
job1.PostString(link,"")
Catch
Log("Exception:"&LastException)
End Try
End Sub
What's the exception message?
It seems that you post an empty string to the server, what contents do the server (192.168.1.110:8080) expects? Is there any server log available?
"Cannot POST /" isn't a Exception message. It's a message show in B4j log windows when i run job1.Poststring(,,).
The link isn't a empty string. Hostip and hostport are my class property.
What's the exception message?
It seems that you post an empty string to the server, what contents do the server (192.168.1.110:8080) expects? Is there any server log available?
Sub run
Dim job1 As HttpJob
Try
job1.Initialize("run",Me)
Dim link As String="http://" & Hostip & ":" & Hostport & "/run"
job1.Download(link)
Catch
Log("Exception:" & LastException)
End Try
End Sub