Been looking through manuals and other posts about how to use SIGNAL ON HALT. Unless i'm missing some then SIGNAL ON HALT is meant to return control back to the REXX code for you to handle the condition. Do I have this right?
If so it doesn't appear to be working or I have something wrong as all it will do is give me the "Enter HI to interrupt" message. So code looks roughly like
signal on halt
"ISPEXEC VGET ZPANELID" /* GET THE CURRENT PANELID */
"ISPEXEC control display lock"
"ISPEXEC display panel("ZPANELID")"
halt: say 'you hit attention'
I never get to the halt label. I have tried checking that ATTENTION is mapped to the key I'm hitting, even re-mapped it elsewhere.
Well, the interrupt would be in the panel processing, not in the REXX code. When you hit the attention key (PA1 by default), you get an ATTN interrupt, not an external interrupt. And as I read the ISPF manual you can trap an ATTN in CLIST, but not in REXX. An ATTN while running REXX terminates the REXX pgm.