Sub One
....do something
callsub Two
Wait for Timer1_Tick
Timer1.enabled = false
.... do somethink
end sub
Sub Two
.......do something
file.copy(file.dirassets,"Book.txt",file.dirinternal,"Odissea.txt")
.......do something
do until file.exists(File.dirinternal,"Odissea.txt")
log("Copy not finished")
Sleep (500)
Loop
timer1.Inizialize("Timer1",1)
timer1.enabled = true
end sub
sub Timer1_tick
timer1.enabled = false
End sub[/CODE
It works but my question is : Are there other best solution to continue code only when the async func of a sub is finished ?