I have been trying to to debug this code.
CASE "SUB", "FUNCTION"
InSub% = 1
MainZ% = 0
UCWord$ = UCASE$(WordZ$(NextToLastWord))
IF UCWord$ = "PUBLIC" THEN
DeleteWord NextToLastWord
END IF
RESET SubTypeName$()
EXIT SUB
It's like the laws of the universe has been changed.
The debugger says UCWord$ = "PUBLIC", but when it gets to the "IF", it jumps over the "deleteword NextToLastWord" to "RESET SubTypeName$()"
I even put in a MSGBOX and it said that UCWord$ equals public"
Am I living in some weird parallel uinverse ?
I tried the following and this works. It makes no sense!
CASE "SUB", "FUNCTION"
InSub% = 1
MainZ% = 0
UCWord$ = "PUBLIC" 'UCASE$(WordZ$(NextToLastWord))
IF UCWord$ = "PUBLIC" THEN
DeleteWord NextToLastWord
END IF
RESET SubTypeName$()
EXIT SUB
Anyone have any ideas ?