Xojo.Net.HTTPSocket

I need help with this topic.

How can I send data from a client application to the server?
And, receiving a response to the data requested.

Thanks in advance.

Server:

Dim data As Text=DefineEncoding(Request.Entity, Encodings.UTF8).ToText
Dim json As JSONItem

Select Case Request.Path

Case “Getthedata”
json = Getdata(data)
Case Else
// Do not process request
Return False
End Select

// Send back data
Request.Print(json.ToString)

Return True

Client:

Self.RequestHeader(“Data”) = “4”
EESocket.Send(“GET”,“https://Mywebpage.com/App_Send/index.cgi/Special/Getthedata”)

In general, Send your message to the server using an HTTPSocker or URLConnection and deal with any results in its PageReceived or ContentReceived event.

This has been covered in lots of docs, blogs and videos which are summarized here:

https://documentation.xojo.com/topics/communication/internet/accessing_web_services.html