I am testing various ways of doing something at the moment, and I need to have a sub called from within a service wait for about a second before it returns. Doing a
in the sub seems to produce strange results; possibly that's due to the side effects of resumable subs. I also tried a simple
loop, but that just seems to block everything, and log messages that should have appeared before the loop don't appear until after it.
Is there any way to create a non-blocking delay of about a second inside a service? Or is there something I can call that would take about a (non-blocking) second to return?
Thanks, Peter
B4X:
sleep(1000)
B4X:
For i = 1 To 1000000: Next
Is there any way to create a non-blocking delay of about a second inside a service? Or is there something I can call that would take about a (non-blocking) second to return?
Thanks, Peter