B4J Question Where can I find the package com.squareup.okhttp?

Marco Gioia

Member
Licensed User
Hello everyone,

I got this error: package com.squareup.okhttp does not exist

B4J Version: 6.30
Parsing code. (0.06s)
Compiling code. (0.20s)
Compiling layouts code. (0.01s)
Organizing libraries. (0.00s)
Compiling generated Java code. Error
javac 1.8.0_144
src\b4j\example\main.java:16: error: package com.squareup.okhttp does not exist
import com.squareup.okhttp.Authenticator;
^
1 error

Where can I find a link to download the package?

Thanks
 

DonManfred

Expert
Licensed User
Longtime User
add jokhttputils to your project.
 
Upvote 0

Marco Gioia

Member
Licensed User
I dont know what you are doing. It is working in a lot of B4J Apps from me.

Upload a small project which shoes the issue.

And if you remove the comment...

B4J Version: 6.30
Parsing code. (0.00s)
Compiling code. Error
Error compiling program.
Error description: Unknown member: hc
Error occurred on line: 22
Jo.RunMethod("SetNTLM", Array("username", "password", "domain", "workstation", HttpUtils2Service.hc)) 'replace the values
Word: hc
 

Attachments

  • NTLM_TEST.zip
    1.6 KB · Views: 331
Last edited:
Upvote 0

DonManfred

Expert
Licensed User
Longtime User
I can´t help you with your inline java.

Usually one uses httpjob to communicate with a Service.
No inline java needed at all.
In b4j there is no httputilsservice like in B4A.

You probably need to add a reference to the okhttp jar(s) and use the correct import WITHOUT trying to use the B4J Client.
I can´t help any further.
 
Upvote 0
Top