Main Board > Nomads
Checking if 'Fired Off From' Nomads
(1/1)
Jeffrey Ferreira:
Hi All,
So often times we will gosub or perform a routine that is also the code behind a multi-line. For Example CUSTOMER_ID_ENTERED.
When we want to know if this came from nomads or from code we check ID$="CUSTOMER_ID".
I know it may seem like I'm splitting hairs but i feel this is not 100% foolproof and i have case where I really need to know (was this routine fired off from Nomads via the multi-line)
is there a way i can be 100% sure?
thanks
jeff
Mike King:
Jeff
You likely could use TCB( 8 ) to see if there is anything on the GOSUB stack since if the routine is PERFORMED then the GOSUB stack will be empty.
--- Code: ---0010 GOSUB test
0020 PERFORM PGN+";test"
0030 GOSUB test2
0040 END
0050 !
0060 test2:
0070 PERFORM PGN+";test"
0080 RETURN
0090 test:
0100 PRINT "TCB ( 8 )=",TCB(8)
0110 RETURN
--- End code ---
-:run
TCB ( 8 )= 20
TCB ( 8 )= 0
TCB ( 8 )= 0
-:
Jeffrey Ferreira:
Mike that is perfect ...thank you...
Navigation
[0] Message Index
Go to full version