Bug? If ... Then Wait For (on one line)

AppLex

New Member
Licensed User
There seems to be a problem when using If … Then Wait For on one line:
B4X:
Private x As Int = 4

If x < 5 Then Wait For SecondSub_Complete

This code results in the following error: "Undeclared variable 'wait' is used before it was assigned any value."

The following version works fine:
B4X:
    Private x As Int = 4
 
If x < 5 Then
     Wait For SecondSub_Complete
End If
 
Last edited:
Cookies are required to use this site. You must accept them to continue using the site. Learn more…