Default Console Event Handling

When the Fortran run-time system is initialized, it establishes a default console event handler through the SetConsoleCtrlHandler Win32 API routine. The default handler will respond to the following event types:

These event types will result in an orderly program abort with an appropriate diagnostic message.

Other console events such as a CTRL_LOGOFF_EVENT or CTRL_SHUTDOWN_EVENT are not handled by the default handler. The handler is notified of these events but returns FALSE to the operating system. This allows a Visual Fortran application activated as a Windows service to continue execution when a user logs off.