Hi,
in b4a I use below code to connect my server
App is work when internet is connected.
But there is no internet connection below error is shown in computer b4a's log even my app is released.
ResponseError. Reason: java.net.ConnectException: Failed to connect to 122.145.12.100:1230, Response:
So anyone can know my server's ip address and port in b4a's log just run my app in phone connect with computer.
How to disable log ResponseError. Reason: java.net.ConnectException: Failed to connect to 122.145.12.100:1230, Response:
This error texts are not from my log.
I noticed after run Wait For (j) JobDone(j As HttpJob).
It shows error if no internet connection.
If j.Success Then '<-- this line result is fail so my log also show: ErrorMessage = java.net.ConnectException: Failed to connect to /122.145.12.100:1230.
How can I disable showing errorMessage with ip address in computer's b4a's log when I run my release my app in my phone?
Thanks.
All logs are:
Logger connected to: 46c4fa70
--------- beginning of system
--------- beginning of main
** Activity (main) Pause event (activity is not paused). **
Sleep not resumed (context is paused): aa.test.b4xloadingindicator$ResumableSub_MainLoop
** Activity (main) Create **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
ResponseError. Reason: java.net.ConnectException: Failed to connect to /122.145.12.100:1230, Response:
** Activity (main) Pause event (activity is not paused). **
** Activity (main) Resume **
ResponseError. Reason: java.net.ConnectException: Failed to connect to /122.145.12.100:1230, Response:
** Activity (main) Pause event (activity is not paused). **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create (first time) **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Receiver (httputils2service) Receive (first time) ***
ResponseError. Reason: java.net.ConnectException: Failed to connect to /122.145.12.100:1230, Response:
in b4a I use below code to connect my server
B4X:
Sub TestConnection
Try
Dim j As HttpJob
j.Initialize("", Me)
j.Download("http://122.145.12.100:1230/test")
Wait For (j) JobDone(j As HttpJob)
If j.Success Then
Log(j.GetString)
Else
Log($"ErrorMessage = ${j.ErrorMessage}"$)
End If
j.Release
Catch
j.Release
End Try
End Sub
App is work when internet is connected.
But there is no internet connection below error is shown in computer b4a's log even my app is released.
ResponseError. Reason: java.net.ConnectException: Failed to connect to 122.145.12.100:1230, Response:
So anyone can know my server's ip address and port in b4a's log just run my app in phone connect with computer.
How to disable log ResponseError. Reason: java.net.ConnectException: Failed to connect to 122.145.12.100:1230, Response:
This error texts are not from my log.
I noticed after run Wait For (j) JobDone(j As HttpJob).
It shows error if no internet connection.
If j.Success Then '<-- this line result is fail so my log also show: ErrorMessage = java.net.ConnectException: Failed to connect to /122.145.12.100:1230.
How can I disable showing errorMessage with ip address in computer's b4a's log when I run my release my app in my phone?
Thanks.
All logs are:
Logger connected to: 46c4fa70
--------- beginning of system
--------- beginning of main
** Activity (main) Pause event (activity is not paused). **
Sleep not resumed (context is paused): aa.test.b4xloadingindicator$ResumableSub_MainLoop
** Activity (main) Create **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
ResponseError. Reason: java.net.ConnectException: Failed to connect to /122.145.12.100:1230, Response:
** Activity (main) Pause event (activity is not paused). **
** Activity (main) Resume **
ResponseError. Reason: java.net.ConnectException: Failed to connect to /122.145.12.100:1230, Response:
** Activity (main) Pause event (activity is not paused). **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create (first time) **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Receiver (httputils2service) Receive (first time) ***
ResponseError. Reason: java.net.ConnectException: Failed to connect to /122.145.12.100:1230, Response:
Last edited: