B4J Question Error on jOkHttpUtils2(2.92)

Teech

Member
Licensed User
Longtime User
On B4J (8.50) I try to connect to a Web Service (on private network) with this code:

B4X:
    Dim su As StringUtils
    Dim url As String="https://myurl/ws"
    Dim usr As String=su.EncodeBase64("CREDENTIALS".GetBytes("UTF8"))
    Dim aut As String=$"AuthString"$
    Dim j As HttpJob
    j.Initialize("",Me )
    j.GetRequest.SetHeader("Authorization",aut)
    j.GetRequest.SetContentType("application/json")
    j.PostString(url,usr)
    Wait For(j) JobDone(j As HttpJob)
    If j.Success Then
        Log(j.GetString)
    Else
        Log(j.ErrorMessage)
    End If
    j.Release

But I have an error on line 244 into the library:

Is the first time that I use Web Services and a friend send to me a JS code that connect at this Web Service:
JavaScript:
function send_local(){       
    var url = "https://myurl/ws"
    var cr = "CREDENTIALS";   
    var cr64 = btoa(cr);
    var auth = "authString";   
    var req = new XMLHttpRequest();   
    req.onreadystatechange = function() {
        if (this.readyState === 4 && this.status === 200) {
            console.log(req.responseText);           
        }else{
            console.log(req);
        }
    };   
    req.open("POST", url, true);   
    req.setRequestHeader('Authorization',auth);
    req.setRequestHeader('Content-Type','application/json; charset=utf-8');

Have you got some suggest?
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…