Private Sub Button1_Click
Dim SU As StringUtils
Dim usr, pass As String
usr = "Aladdin"
pass = "open sesame"
Dim s As String = usr & ":" & pass
Dim credentials As String = SU.EncodeBase64(s.GetBytes("UTF8"))
Log(credentials)
Dim b() As Byte = SU.DecodeBase64(credentials)
Dim d As String = BytesToString(b, 0, b.Length, "UTF8")
Log(d)
Dim j As HttpJob
j.Initialize("", Me)
'j.Username = "xxx"
'j.Password = "yyy"
j.Download("http://192.168.0.10:19058/BC190_DD/ODataV4/Company('LA%20COOPERATIVA')/LocationListPage")
'j.GetRequest.Timeout = 3000 * 1000
'j.GetRequest.SetHeader("Content-Type","application/x-www-form-urlencoded; charset=utf-8")
'j.GetRequest.SetContentType("plain/text")
j.GetRequest.SetHeader("Authorization", "Basic " & credentials)
Wait For (j) JobDone(j As HttpJob)
If j.Success Then
Log(j.GetString)
End If
j.Release
End Sub