Re: 4GL interrupt handling
Posted in 1998
LTBeason wrote: > > I am currently writing a program in 4GL that is basically a > daemon process, with no screen i/o. > > Does anyone know of any Informix methods for handling > interrupts other than the DEFER INTERRUPTS statement, > which is for screen i/o. I need to build some interrupt > handling into the program, but have no real ideas how to > do so. > > It has been suggested that I write a c function to do the > interrupt handling. Is this possible ?? Yes it is not only possible but desireable. Building 4GL callable "C" functions is not difficult and is documented in the 4GL manual. The explanation is clear, though not complete. A good 4GL book, there are two or three available one by Art Taylor comes to mind, that give better examples but many of us figured it all out without too much trouble. There are one or two sample C functions in the $INFORMIXDIR/demo/fglbe directory and there are many C functions you can use as templates available from the IIUG Software Repository. You can even have your "C" interrupt handler function call a 4GL handler function and thereby build a general purpose interrupt service for 4GL programs with a register/deregister function and everything. Hey! This sounds like a perfect candidate for submission to the Repository when it is finished! Hmmm you might search there first also this is too useful to have never been submitted. Art S. Kagel