B4J Question HttpJob when Proxy is active - udg    Nov 28, 2022 . What should I do? As an example of data transmission, I have: Dim pJob As HttpJob pJob.Initialize("", Me) pJob.PostBytes(wscsync, buffer) Wait For (pJob) JobDone(j As HttpJob) wscsync is: Public const wscsync As String = "https://<mydomain>:62238/mnog"...): SetSystemProperty("http.proxyHost","webwasher.xxxx.com") SetSystemProperty("https.proxyHost", "webwasher.xxx.com") SetSystemProperty("http... B4A Tutorial [B4X] OkHttpUtils2 with Wait For - Erel    Apr 11, 2021   (56 reactions)   tags: image, wait, Download, Http MySql, Wait For, ws have a single sub that handles all requests results. Simplest example: Dim j As HttpJob j... As HttpJob) If j.Success Then Log(j.GetString) End If j.Release Example of downloading a quote from a quotes service: Sub DownloadQuote Dim j As HttpJob j.Initialize("", Me) 'name...=rand") Wait For (j) JobDone(j As HttpJob) If j.Success Then 'The result...("content")) Next End If j.Release End Sub Note that the HttpJob object is a local... B4A Question [Solved] HttpJob error with unexpected end of stream - max123    May 25, 2024 B4A with OkHttpUtils2 and HttpJob.
Because I will test on Android Emulator, initially I had...)
End Sub
Sub DownloadAndSaveFile (Link As String)
Dim j As HttpJob
j.Initialize(""... B4J Question HttpJob B4X Difference with .NET ? - Magma    Apr 25, 2024 As HttpJob j.Initialize("viva",Me) j.postString(usingurl & "transactions:sale.../json") J.GetRequest.SetContentType("application/json") Wait For (j) JobDone(j As HttpJob) 'Log(j.GetString) If j.Success=True Then If j.GetString.Contains..., "application/json") httpClient.DefaultRequestHeaders.Authorization = New Headers.AuthenticationHeaderValue("Bearer", AccessToken) Dim response = Await httpClient... Bug? Issues with B4A/B4J HttpJob.Response.ContentLength - OliverA    Mar 31, 2024 In B4J and B4A, HttpJob.Response.ContentLength seems to always return 0 when using HttpJob.Head. In... : https://www.b4x.com/android/forum/threads/solved-question-about-okhttputils2-response-contentlength.160216/) This is the code snippet: Dim filename As String = "https://b4x-4c17.kxcdn.com/android/forum/data/avatars/m/86/86664.jpg?1520274433" Dim j As HttpJob j.Initialize("", Me) j.head(filename) Wait For (j) JobDone(j As HttpJob) If j.Success Then... B4A Question How to treat httpjob timeout? - wimpie3    Nov 10, 2021 I want to detect a timeout with httpjob. I'm doing this: Dim Job1 As HttpJob Job1.Initialize(...) Job1.Poststring(...) Job1.GetRequest.Timeout =5000 ' 5 seconds Wait For (j) JobDone(j As HttpJob) If j.Success Then Log("succes") Else Log("failed") End If When I start my app without internet connection, I thought the "failed" message would be shown after 5 seconds. But nothing happens. It seems that Android is trying to do the PostString and "hangs... B4J Question How do I detect a Http_job has timed out when I use Wait For - JackKirk    Sep 9, 2022 I have a Http_job, the bare bones of the relevant code to execute it are: Private XXX_job As Http_Job XXX_job.Initialize("List", Me) wrk_URI stuff here XXX_job.Download(wrk_URI) XXX_job.GetRequest.Timeout = 30 * DateTime.TicksPerSecond 'I know this is the default wrk_Authorization stuff here XXX_job.GetRequest.SetHeader("Authorization", wrk_Authorization) Wait For (XXX_job) JobDone (Job As Http_Job) Occasionally... B4J Question [Banano] Converting httpjob code from B4A - toby    Sep 8, 2022 .ToPrettyString(1) 'indent by 1 space Dim J As HttpJob 'depends OKHttpUtils2 J.Initialize("J",Me) J.PostString("https://mysite.com/getdetail.php" , data ) Wait For (j) JobDone(j As HttpJob) If j.Success=False Then j.Release Log... B4A Question HttpJob not connecting to Localhost - DawningTruth    Jan 27, 2023 Dim httpJob As HttpJob httpJob.Initialize("", Me) httpJob.PostString(apiUrl, jsonPostValue) httpJob.GetRequest.SetContentType("application/json") httpJob... Start Download Job") Wait For (httpJob) JobDone(httpJob As HttpJob) Log("FINISHED: ApiFetch -> End Download Job") If httpJob.Success Then Log(httpJob.GetString) apiReturn = httpJob.GetString Else Log("Error: " & httpJob... B4A Question Wait For ...j As HttpJob - can be long... is there a way to exit it ? - Magma    Nov 1, 2024 ...
is there a way to exit the following - for example at 20seconds?:
Wait For (j) JobDone(j As HttpJob)
any idea.... or tip ?
Thanks in advance... Page: 1   2   3   4   5   6   7   |