the following code :
does not raise any red issues / warning issues from the IDE (b4J).
but it does NOT log "2" (as expected ??).
only if the 'log(2)' moved to next line - it logs it ok.
so, if writing this way is a syntax mistake/error - the IDE should warn you about that.
and if not, it should work (as expected ??).
BTW - just tried it on vb6 ide - it's accepted and works there. (not that it binds b4x in any way).
if i'm missing something, please let me know. thank you.
B4X:
Dim a As Int
a=2
If a =1 Then
Log(1)
Else If a=2 Then Log(2)
End If
but it does NOT log "2" (as expected ??).
only if the 'log(2)' moved to next line - it logs it ok.
so, if writing this way is a syntax mistake/error - the IDE should warn you about that.
and if not, it should work (as expected ??).
BTW - just tried it on vb6 ide - it's accepted and works there. (not that it binds b4x in any way).
if i'm missing something, please let me know. thank you.