Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: AIBCVT6

AIBCVT6.m

Go to the documentation of this file.
AIBCVT6 ;IHS/DDPS/DFM-IBM STAT RECORD ERROR/EOJ [ 02/01/89  8:54 AM ]
 ;1.3; 9/23/88 RESTRUCTURE, ALLOW FOR REGISTRATION ELIGIBILITY FILE
 ;1.0; 3/28/88
 ;1.1; 5/30/88 ; ADD DSM LOGIC
ERRMSG ;PRINT ERROR MESSAGE TO CONSOLE AND PRINTER
 U AIBCDV W !,AIBMSG
ERRMSP ; WRITE ERROR MESSAGE TO PRINTER ONLY
 G:'$D(AIBPDV) RETURN U AIBPDV W !,AIBMSG S AIBMSG="" G RETURN
OPCANCL ;OPERATOR CANCLED JOB
 D:$L(AIBMSG)>0 ERRMSG S AIBMSG="Operator Canceled Job"
 G ABEND
MTERR ;ERROR WRITEING MAGTAPE
 S AIBMSG="Write Error" D ERRMSG
ABEND ;ABNORMAL END OF JOB
 D:$L(AIBMSG)>0 ERRMSG S AIBMSG="ABNORMAL END OF JOB"
 D ERRMSG S AIBOK="N" G RETURN
CLOSEND ;EOJ OF JOB PROCESSING
 D DATIME W ! S AIBMSG="Processing Ended "_AIBDT_" "_AIBTI D ERRMSG
 G:'$D(AIBT1) CLOSPRNT I AIBOS="M" S AIBMSG="File Created : "_AIBT1 D ERRMSG
CLOSPRNT ;
 U AIBCDV S (IO,AIBDEV)=AIBPDV D CLOSE^AIBSDEV
 G:AIBTDV="" KILLALL S (IO,AIBDEV)=AIBTDV D CLOSE^AIBSDEV
KILLALL ;KILL ALL LOCAL VARIABLES AND INPUT DATA GLOBAL
 K:'$D(AIBOK) @AIBGBL
 K AIB2ND,AIBA,AIBAGI,AIBAGO,AIBB,AIBB1,AIBB2,AIBB3
 K AIBC,AIBCDV,AIBCF,AIBCF1,AIBCF2,AIBCF3,AIBCK,AIBCL
 K AIBCN1,AIBCN2,AIBCN3,AIBC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