Kostas_Bar
Member
Hello everyone!
I have created an app that akes lot's of API Calls. Some times the connection to the server isn't easy, so the app has to wait. This is why I have added a Loading Indicator for the user to know that everything works fine, they just have to wait a few seconds.
Nevertheless, the way I 've written it, the indicator appears in every API Call (and dozens of them are happening in this app) for a short period.
I wand it to appear only if the wait lasts more than 1 or 2 seconds.
Is this possible? Thank you in advance.
I have created an app that akes lot's of API Calls. Some times the connection to the server isn't easy, so the app has to wait. This is why I have added a Loading Indicator for the user to know that everything works fine, they just have to wait a few seconds.
Nevertheless, the way I 've written it, the indicator appears in every API Call (and dozens of them are happening in this app) for a short period.
I wand it to appear only if the wait lasts more than 1 or 2 seconds.
Wait For With Loading Indicator:
Dim j As HttpJob
j.Initialize("", Me)
LoadIndicatorTabReturn.Show
j.PostString(link, m.As(JSON).ToCompactString)
j.GetRequest.SetHeader("Authorization", "Bearer " & token)
j.GetRequest.SetContentType("application/json")
Wait For (j) JobDone (j As HttpJob)
LoadIndicatorTabReturn.Hide
Is this possible? Thank you in advance.