How can I determine the 'SCREEN' setting from within my SBX procedure? I need to determine whether it is 'SCREEN ON' or 'SCREEN OFF'?
The CA Ramis SBX variable %TERMINAL will tell you.
From the CA Ramis System Building Executive (SBX) manual, section 9.2.1 Identifying the Operating Mode:
"... The %TERMINAL system variable identifies the operating mode (batch or interactive), and, if the mode is interactive, the terminal type to which RAMSYSIN is directed. Possible values are: The %TERMINAL variable is set by CA Ramis. Value Mode or Terminal ----- ---------------- 0 Batch. 1 Teletype or video display terminal without Screen Manager. 2 Model 2 (24x80) video display terminal. 3 Model 3 (32x80) video display terminal. 4 Model 4 (43x80) video display terminal. 5 Model 5 (27x132) video display terminal. ..."
So, you can test the value of %TERMINAL in your SBX procedure during execution.
The value 1 indicates that this SBX procedure is executing with SCREEN OFF, the value 0 indicates that this is running in batch, and values 2-5 indicate that this is running with SCREEN ON and what terminal type is running on.