DVBAB1C ;ALB/AJF;CAPRI UTILITIES ; 10/13/21 8:02am
;;2.7;AMIE;**193,227**;Apr 10, 1995;Build 21
;Per VHA Directive 2004-038, this routine should not be modified.
;
Q
;
MSG(RIEN) ;Generate mail message;AJF
;
D GETREQ
D MGUSR
;
S XMSUB="CAPRI: 2507 Exam Request Rejected"
S ^TMP($J,"AMIE1",1)="The 2507 Exam Request as described below has been rejected."
S ^TMP($J,"AMIE1",2)=""
S ^TMP($J,"AMIE1",3)=""
S ^TMP($J,"AMIE1",4)=" DFN: `"_DVBADFN
S ^TMP($J,"AMIE1",5)=" Requested Date: "_DVBADT
S ^TMP($J,"AMIE1",6)=" Requested Site: "_RTF
S ^TMP($J,"AMIE1",7)=""
S ^TMP($J,"AMIE1",8)=" Rerouted Date: "_RDT
S ^TMP($J,"AMIE1",9)=" Rerouted Site: "_RTO
S ^TMP($J,"AMIE1",10)=""
;changes for patch 227 displaying reject date/reason
S ^TMP($J,"AMIE1",11)=" Rejected Date: "_RRRD
S ^TMP($J,"AMIE1",12)=" Rejected Reason: "_RRRJ
S ^TMP($J,"AMIE1",13)=""
S ^TMP($J,"AMIE1",14)=""
S ^TMP($J,"AMIE1",15)="**NOTE: To view the patient using the DFN, paste the DFN number into the CAPRI"
S ^TMP($J,"AMIE1",16)="Patient Selector 'Patient ID' field to find the patient. Be sure to include"
S ^TMP($J,"AMIE1",17)="the ` (backward-apostrophe) character."
S ^TMP($J,"AMIE1",18)=""
S ^TMP($J,"AMIE1",19)=""
S ^TMP($J,"AMIE1",20)=""
S ^TMP($J,"AMIE1",21)="*****This is an auto-generated email. Do not respond to this email address.*****"
S XMTEXT="^TMP($J,""AMIE1"","
D ^XMD,END
Q
;
;
AMSG(RIEN) ;Generate Acceptance Email
;
D GETREQ
D MGUSR
;
S XMSUB="CAPRI: 2507 Exam Request Accepted"
S ^TMP($J,"AMIE1",1)="The 2507 Exam Request as described below has been ACCEPTED."
S ^TMP($J,"AMIE1",2)=""
S ^TMP($J,"AMIE1",3)=""
S ^TMP($J,"AMIE1",4)=" DFN: `"_DVBADFN
S ^TMP($J,"AMIE1",5)=" Requested Date: "_DVBADT
S ^TMP($J,"AMIE1",6)=" Requested Site: "_RTF
S ^TMP($J,"AMIE1",7)=""
S ^TMP($J,"AMIE1",8)=" Rerouted Date: "_RDT
S ^TMP($J,"AMIE1",9)=" Rerouted Site: "_RTO
S ^TMP($J,"AMIE1",10)=""
S ^TMP($J,"AMIE1",11)=""
S ^TMP($J,"AMIE1",12)="**NOTE: To view the patient using the DFN, paste the DFN number into the CAPRI"
S ^TMP($J,"AMIE1",13)="Patient Selector 'Patient ID' field to find the patient. Be sure to include"
S ^TMP($J,"AMIE1",14)="the ` (backward-apostrophe) character."
S ^TMP($J,"AMIE1",15)=""
S ^TMP($J,"AMIE1",16)=""
S ^TMP($J,"AMIE1",17)=""
S ^TMP($J,"AMIE1",18)="*****This is an auto-generated email. Do not respond to this email address.*****"
S XMTEXT="^TMP($J,""AMIE1"","
D ^XMD,END
Q
;
FINDEXAM(ZMSG,ZIEN) ;Returns list of exams in 396.4 that are linked to ZIEN in 396.3
N DVBABCNT,DVBABIEN
S DVBABCNT=0,DVBABIEN=0
F S DVBABIEN=$O(^DVB(396.4,"C",ZIEN,DVBABIEN)) Q:'DVBABIEN D
.S DVBABD1=$P($G(^DVB(396.4,DVBABIEN,0)),"^",2)
.S DVBABD2=$P($G(^DVB(396.6,+$P($G(^DVB(396.4,DVBABIEN,0)),"^",3),0)),"^",1) ;Name of Exam
.S DVBABD3=$P($G(^DVB(396.4,DVBABIEN,0)),"^",4)
.I DVBABD3="O" S DVBABD3="[OPEN]"
.I DVBABD3="C" S DVBABD3="[COMPLETE]"
.I DVBABD3="X" S DVBABD3="[CANCELED BY MAS]"
.I DVBABD3="RX" S DVBABD3="[CANCELED BY RO]"
.I DVBABD3="T" S DVBABD3="[TRANSFERRED OUT]"
.I ZIEN=DVBABD1 D
..S ZMSG(DVBABCNT)=DVBABIEN_"^"_DVBABD2_" "_DVBABD3
..S DVBABCNT=DVBABCNT+1
K DVBABCNT,DVBABIEN,ZIEN,DVBABD1,DVBABD2,DVBABD3
Q
;
;
SENDMSG(RIEN) ;SET UP TO SEND EMAIL/NOTIFICATION TO REQUESTOR OF 2507
D GETREQ
Q:DVBAEA=""
;
RDYMSG ;SEND REROUTED MESSAGE TO REQUESTOR OF 2507
;no text/body is passed in so we have to build the message from scratch
S XMSUB="CAPRI: 2507 Exam Request Rerouted"
S ^TMP($J,"AMIE1",1)="The 2507 Exam Request as described below has been rerouted."
S ^TMP($J,"AMIE1",2)=""
S ^TMP($J,"AMIE1",3)=""
S ^TMP($J,"AMIE1",4)=" DFN: `"_DVBADFN
S ^TMP($J,"AMIE1",5)=" Requested Date: "_DVBADT
S ^TMP($J,"AMIE1",6)=" Requested Site: "_RTF
S ^TMP($J,"AMIE1",7)=" Requested By: "_DVBNM
S ^TMP($J,"AMIE1",8)=""
S ^TMP($J,"AMIE1",9)=" Rerouted Date: "_RDT
S ^TMP($J,"AMIE1",10)=" Rerouted Site: "_RTO
S ^TMP($J,"AMIE1",11)=""
S ^TMP($J,"AMIE1",12)=" Reroute Reason: "_RRR
S ^TMP($J,"AMIE1",13)=" Reroute Description: "_RRD
S ^TMP($J,"AMIE1",14)=""
S ^TMP($J,"AMIE1",15)=""
S ^TMP($J,"AMIE1",16)="**NOTE: To view the patient using the DFN, paste the DFN number into the CAPRI"
S ^TMP($J,"AMIE1",17)="Patient Selector 'Patient ID' field to find the patient. Be sure to include"
S ^TMP($J,"AMIE1",18)="the ` (backward-apostrophe) character."
S ^TMP($J,"AMIE1",19)=""
S ^TMP($J,"AMIE1",20)=""
S ^TMP($J,"AMIE1",21)=""
S ^TMP($J,"AMIE1",22)="*****This is an auto-generated email. Do not respond to this email address.*****"
S XMTEXT="^TMP($J,""AMIE1"","
D ^XMD,END
Q
;
GETREQ ; Get infor the RIEN
N DVBA0,DVBAREQ,DVBAC,DVBAQUIT,DUZ
N MSG,MERR,CTR
;SINCE MAILMAN DOES NOT ALLOW MESSAGES TO BE SENT FROM USERS WITHOUT ACCESS CODES OR MAILBOXES
;WHICH CAPRI REMOTE USER DO NOT HAVE, WE HAVE TO NEW DUZ AND CHANGE XMDUZ TO THE NAME OF THE USER
;AS A STRING SO THE PROCESS IS STILL LINKED TO THE USER SENDING/TRIGGERING THE MESSAGE
S DVBA0=$G(^DVB(396.3,RIEN,0))
S DVBADFN=$P(DVBA0,"^",1),DVBAREQ=$P(DVBA0,"^",4)
;S XMDUZ=$P(^VA(200,DVBAREQ,0),"^",1)_" CAPRI"
S XMDUZ="CAPRI "_$P(^VA(200,.5,0),"^",1)
S DVBADT=$$FMTE^XLFDT($P(DVBA0,"^",2))
;following call supported by IA 3858
S DVBAEA=$P($G(^VA(200,DVBAREQ,.15)),"^",1)
S DVBNM=$P($G(^VA(200,DVBAREQ,0)),"^",1)
S J1=$O(^DVB(396.3,RIEN,6,99999),-1)
S J2=$O(^DVB(396.3,RIEN,6,J1,1,99999),-1)
S J10=^DVB(396.3,RIEN,6,J1,0),J20=^DVB(396.3,RIEN,6,J1,1,J2,0)
;changes for patch 227 adding reject reason in reject message
S RRRJ=$G(^DVB(396.3,RIEN,6,J1,1,J2,1))
S:RRRJ="" RRRJ="None"
S RRR=$$EXTERNAL^DILFD(396.34,4,,$P(J10,"^",5))
S RRD=$P(J10,"^",6)
S:RRD="" RRD="None"
S RDT=$$EXTERNAL^DILFD(396.34,.01,,$P(J10,"^",1))
S RTO=$$EXTERNAL^DILFD(396.34,.02,,$P(J10,"^",7))
S RTF=$$EXTERNAL^DILFD(396.34,3,,$P(J10,"^",4))
S RRRD=$$EXTERNAL^DILFD(396.341,.01,,$P(J20,"^",1))
I DVBAEA="" Q
S XMY(DVBAEA)="",DVBASITE=$$SITE^VASITE
K J1,J10,J2,J20
;
Q
;
MGUSR ; set email addresses from mail group
; Supported References:
; DBIA #10111: Allows FM read access of ^XMB(3.8,D0,0) using DIC.
;
N MGN,XMB,DIC,MMG,MDIEN,DVEM,MMUS,ERR
S MGN="DVBA C 2507 REROUTE",XMB="DVBA CAPRI REROUTE"
S XMDUZ="CAPRI "_$P(^VA(200,.5,0),"^",1)
S DIC="^XMB(3.8,",DIC(0)="QM",X=MGN D ^DIC
I +Y<0 S ERR="INVALID MAIL GROUP NAME" Q
S MDIEN=+Y,MMG=0
I '$$GOTLOCAL^XMXAPIG(MGN) S ERR="NO ACTIVE LOCAL MEMBERS IN MAIL GROUP" K ^TMP("XMERR",$J) Q
F S MMG=$O(^XMB(3.8,MDIEN,1,MMG)) Q:MMG="B" D
.S MMUS=$P($G(^XMB(3.8,MDIEN,1,MMG,0)),"^",1)
.S DVEM=$P($G(^VA(200,MMUS,.15)),"^",1)
.Q:DVEM=""
.S XMY(DVEM)=""
Q
;
END ;
K RDT,RRD,RRR,RRRJ,RTF,RTO,X,XMY,XMSUB,XMTEXT,MGN,DIC,DIC(0),J,Y,XMDUZ,XMB,ERR,RRRD
K ^TMP($J,"AMIE1"),DVBADFN,DVBASITE,DVBADT,DVBAEA,DVBNM
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HDVBAB1C 7148 printed Dec 13, 2024@01:40:21 Page 2
DVBAB1C ;ALB/AJF;CAPRI UTILITIES ; 10/13/21 8:02am
+1 ;;2.7;AMIE;**193,227**;Apr 10, 1995;Build 21
+2 ;Per VHA Directive 2004-038, this routine should not be modified.
+3 ;
+4 QUIT
+5 ;
MSG(RIEN) ;Generate mail message;AJF
+1 ;
+2 DO GETREQ
+3 DO MGUSR
+4 ;
+5 SET XMSUB="CAPRI: 2507 Exam Request Rejected"
+6 SET ^TMP($JOB,"AMIE1",1)="The 2507 Exam Request as described below has been rejected."
+7 SET ^TMP($JOB,"AMIE1",2)=""
+8 SET ^TMP($JOB,"AMIE1",3)=""
+9 SET ^TMP($JOB,"AMIE1",4)=" DFN: `"_DVBADFN
+10 SET ^TMP($JOB,"AMIE1",5)=" Requested Date: "_DVBADT
+11 SET ^TMP($JOB,"AMIE1",6)=" Requested Site: "_RTF
+12 SET ^TMP($JOB,"AMIE1",7)=""
+13 SET ^TMP($JOB,"AMIE1",8)=" Rerouted Date: "_RDT
+14 SET ^TMP($JOB,"AMIE1",9)=" Rerouted Site: "_RTO
+15 SET ^TMP($JOB,"AMIE1",10)=""
+16 ;changes for patch 227 displaying reject date/reason
+17 SET ^TMP($JOB,"AMIE1",11)=" Rejected Date: "_RRRD
+18 SET ^TMP($JOB,"AMIE1",12)=" Rejected Reason: "_RRRJ
+19 SET ^TMP($JOB,"AMIE1",13)=""
+20 SET ^TMP($JOB,"AMIE1",14)=""
+21 SET ^TMP($JOB,"AMIE1",15)="**NOTE: To view the patient using the DFN, paste the DFN number into the CAPRI"
+22 SET ^TMP($JOB,"AMIE1",16)="Patient Selector 'Patient ID' field to find the patient. Be sure to include"
+23 SET ^TMP($JOB,"AMIE1",17)="the ` (backward-apostrophe) character."
+24 SET ^TMP($JOB,"AMIE1",18)=""
+25 SET ^TMP($JOB,"AMIE1",19)=""
+26 SET ^TMP($JOB,"AMIE1",20)=""
+27 SET ^TMP($JOB,"AMIE1",21)="*****This is an auto-generated email. Do not respond to this email address.*****"
+28 SET XMTEXT="^TMP($J,""AMIE1"","
+29 DO ^XMD
DO END
+30 QUIT
+31 ;
+32 ;
AMSG(RIEN) ;Generate Acceptance Email
+1 ;
+2 DO GETREQ
+3 DO MGUSR
+4 ;
+5 SET XMSUB="CAPRI: 2507 Exam Request Accepted"
+6 SET ^TMP($JOB,"AMIE1",1)="The 2507 Exam Request as described below has been ACCEPTED."
+7 SET ^TMP($JOB,"AMIE1",2)=""
+8 SET ^TMP($JOB,"AMIE1",3)=""
+9 SET ^TMP($JOB,"AMIE1",4)=" DFN: `"_DVBADFN
+10 SET ^TMP($JOB,"AMIE1",5)=" Requested Date: "_DVBADT
+11 SET ^TMP($JOB,"AMIE1",6)=" Requested Site: "_RTF
+12 SET ^TMP($JOB,"AMIE1",7)=""
+13 SET ^TMP($JOB,"AMIE1",8)=" Rerouted Date: "_RDT
+14 SET ^TMP($JOB,"AMIE1",9)=" Rerouted Site: "_RTO
+15 SET ^TMP($JOB,"AMIE1",10)=""
+16 SET ^TMP($JOB,"AMIE1",11)=""
+17 SET ^TMP($JOB,"AMIE1",12)="**NOTE: To view the patient using the DFN, paste the DFN number into the CAPRI"
+18 SET ^TMP($JOB,"AMIE1",13)="Patient Selector 'Patient ID' field to find the patient. Be sure to include"
+19 SET ^TMP($JOB,"AMIE1",14)="the ` (backward-apostrophe) character."
+20 SET ^TMP($JOB,"AMIE1",15)=""
+21 SET ^TMP($JOB,"AMIE1",16)=""
+22 SET ^TMP($JOB,"AMIE1",17)=""
+23 SET ^TMP($JOB,"AMIE1",18)="*****This is an auto-generated email. Do not respond to this email address.*****"
+24 SET XMTEXT="^TMP($J,""AMIE1"","
+25 DO ^XMD
DO END
+26 QUIT
+27 ;
FINDEXAM(ZMSG,ZIEN) ;Returns list of exams in 396.4 that are linked to ZIEN in 396.3
+1 NEW DVBABCNT,DVBABIEN
+2 SET DVBABCNT=0
SET DVBABIEN=0
+3 FOR
SET DVBABIEN=$ORDER(^DVB(396.4,"C",ZIEN,DVBABIEN))
if 'DVBABIEN
QUIT
Begin DoDot:1
+4 SET DVBABD1=$PIECE($GET(^DVB(396.4,DVBABIEN,0)),"^",2)
+5 ;Name of Exam
SET DVBABD2=$PIECE($GET(^DVB(396.6,+$PIECE($GET(^DVB(396.4,DVBABIEN,0)),"^",3),0)),"^",1)
+6 SET DVBABD3=$PIECE($GET(^DVB(396.4,DVBABIEN,0)),"^",4)
+7 IF DVBABD3="O"
SET DVBABD3="[OPEN]"
+8 IF DVBABD3="C"
SET DVBABD3="[COMPLETE]"
+9 IF DVBABD3="X"
SET DVBABD3="[CANCELED BY MAS]"
+10 IF DVBABD3="RX"
SET DVBABD3="[CANCELED BY RO]"
+11 IF DVBABD3="T"
SET DVBABD3="[TRANSFERRED OUT]"
+12 IF ZIEN=DVBABD1
Begin DoDot:2
+13 SET ZMSG(DVBABCNT)=DVBABIEN_"^"_DVBABD2_" "_DVBABD3
+14 SET DVBABCNT=DVBABCNT+1
End DoDot:2
End DoDot:1
+15 KILL DVBABCNT,DVBABIEN,ZIEN,DVBABD1,DVBABD2,DVBABD3
+16 QUIT
+17 ;
+18 ;
SENDMSG(RIEN) ;SET UP TO SEND EMAIL/NOTIFICATION TO REQUESTOR OF 2507
+1 DO GETREQ
+2 if DVBAEA=""
QUIT
+3 ;
RDYMSG ;SEND REROUTED MESSAGE TO REQUESTOR OF 2507
+1 ;no text/body is passed in so we have to build the message from scratch
+2 SET XMSUB="CAPRI: 2507 Exam Request Rerouted"
+3 SET ^TMP($JOB,"AMIE1",1)="The 2507 Exam Request as described below has been rerouted."
+4 SET ^TMP($JOB,"AMIE1",2)=""
+5 SET ^TMP($JOB,"AMIE1",3)=""
+6 SET ^TMP($JOB,"AMIE1",4)=" DFN: `"_DVBADFN
+7 SET ^TMP($JOB,"AMIE1",5)=" Requested Date: "_DVBADT
+8 SET ^TMP($JOB,"AMIE1",6)=" Requested Site: "_RTF
+9 SET ^TMP($JOB,"AMIE1",7)=" Requested By: "_DVBNM
+10 SET ^TMP($JOB,"AMIE1",8)=""
+11 SET ^TMP($JOB,"AMIE1",9)=" Rerouted Date: "_RDT
+12 SET ^TMP($JOB,"AMIE1",10)=" Rerouted Site: "_RTO
+13 SET ^TMP($JOB,"AMIE1",11)=""
+14 SET ^TMP($JOB,"AMIE1",12)=" Reroute Reason: "_RRR
+15 SET ^TMP($JOB,"AMIE1",13)=" Reroute Description: "_RRD
+16 SET ^TMP($JOB,"AMIE1",14)=""
+17 SET ^TMP($JOB,"AMIE1",15)=""
+18 SET ^TMP($JOB,"AMIE1",16)="**NOTE: To view the patient using the DFN, paste the DFN number into the CAPRI"
+19 SET ^TMP($JOB,"AMIE1",17)="Patient Selector 'Patient ID' field to find the patient. Be sure to include"
+20 SET ^TMP($JOB,"AMIE1",18)="the ` (backward-apostrophe) character."
+21 SET ^TMP($JOB,"AMIE1",19)=""
+22 SET ^TMP($JOB,"AMIE1",20)=""
+23 SET ^TMP($JOB,"AMIE1",21)=""
+24 SET ^TMP($JOB,"AMIE1",22)="*****This is an auto-generated email. Do not respond to this email address.*****"
+25 SET XMTEXT="^TMP($J,""AMIE1"","
+26 DO ^XMD
DO END
+27 QUIT
+28 ;
GETREQ ; Get infor the RIEN
+1 NEW DVBA0,DVBAREQ,DVBAC,DVBAQUIT,DUZ
+2 NEW MSG,MERR,CTR
+3 ;SINCE MAILMAN DOES NOT ALLOW MESSAGES TO BE SENT FROM USERS WITHOUT ACCESS CODES OR MAILBOXES
+4 ;WHICH CAPRI REMOTE USER DO NOT HAVE, WE HAVE TO NEW DUZ AND CHANGE XMDUZ TO THE NAME OF THE USER
+5 ;AS A STRING SO THE PROCESS IS STILL LINKED TO THE USER SENDING/TRIGGERING THE MESSAGE
+6 SET DVBA0=$GET(^DVB(396.3,RIEN,0))
+7 SET DVBADFN=$PIECE(DVBA0,"^",1)
SET DVBAREQ=$PIECE(DVBA0,"^",4)
+8 ;S XMDUZ=$P(^VA(200,DVBAREQ,0),"^",1)_" CAPRI"
+9 SET XMDUZ="CAPRI "_$PIECE(^VA(200,.5,0),"^",1)
+10 SET DVBADT=$$FMTE^XLFDT($PIECE(DVBA0,"^",2))
+11 ;following call supported by IA 3858
+12 SET DVBAEA=$PIECE($GET(^VA(200,DVBAREQ,.15)),"^",1)
+13 SET DVBNM=$PIECE($GET(^VA(200,DVBAREQ,0)),"^",1)
+14 SET J1=$ORDER(^DVB(396.3,RIEN,6,99999),-1)
+15 SET J2=$ORDER(^DVB(396.3,RIEN,6,J1,1,99999),-1)
+16 SET J10=^DVB(396.3,RIEN,6,J1,0)
SET J20=^DVB(396.3,RIEN,6,J1,1,J2,0)
+17 ;changes for patch 227 adding reject reason in reject message
+18 SET RRRJ=$GET(^DVB(396.3,RIEN,6,J1,1,J2,1))
+19 if RRRJ=""
SET RRRJ="None"
+20 SET RRR=$$EXTERNAL^DILFD(396.34,4,,$PIECE(J10,"^",5))
+21 SET RRD=$PIECE(J10,"^",6)
+22 if RRD=""
SET RRD="None"
+23 SET RDT=$$EXTERNAL^DILFD(396.34,.01,,$PIECE(J10,"^",1))
+24 SET RTO=$$EXTERNAL^DILFD(396.34,.02,,$PIECE(J10,"^",7))
+25 SET RTF=$$EXTERNAL^DILFD(396.34,3,,$PIECE(J10,"^",4))
+26 SET RRRD=$$EXTERNAL^DILFD(396.341,.01,,$PIECE(J20,"^",1))
+27 IF DVBAEA=""
QUIT
+28 SET XMY(DVBAEA)=""
SET DVBASITE=$$SITE^VASITE
+29 KILL J1,J10,J2,J20
+30 ;
+31 QUIT
+32 ;
MGUSR ; set email addresses from mail group
+1 ; Supported References:
+2 ; DBIA #10111: Allows FM read access of ^XMB(3.8,D0,0) using DIC.
+3 ;
+4 NEW MGN,XMB,DIC,MMG,MDIEN,DVEM,MMUS,ERR
+5 SET MGN="DVBA C 2507 REROUTE"
SET XMB="DVBA CAPRI REROUTE"
+6 SET XMDUZ="CAPRI "_$PIECE(^VA(200,.5,0),"^",1)
+7 SET DIC="^XMB(3.8,"
SET DIC(0)="QM"
SET X=MGN
DO ^DIC
+8 IF +Y<0
SET ERR="INVALID MAIL GROUP NAME"
QUIT
+9 SET MDIEN=+Y
SET MMG=0
+10 IF '$$GOTLOCAL^XMXAPIG(MGN)
SET ERR="NO ACTIVE LOCAL MEMBERS IN MAIL GROUP"
KILL ^TMP("XMERR",$JOB)
QUIT
+11 FOR
SET MMG=$ORDER(^XMB(3.8,MDIEN,1,MMG))
if MMG="B"
QUIT
Begin DoDot:1
+12 SET MMUS=$PIECE($GET(^XMB(3.8,MDIEN,1,MMG,0)),"^",1)
+13 SET DVEM=$PIECE($GET(^VA(200,MMUS,.15)),"^",1)
+14 if DVEM=""
QUIT
+15 SET XMY(DVEM)=""
End DoDot:1
+16 QUIT
+17 ;
END ;
+1 KILL RDT,RRD,RRR,RRRJ,RTF,RTO,X,XMY,XMSUB,XMTEXT,MGN,DIC,DIC(0),J,Y,XMDUZ,XMB,ERR,RRRD
+2 KILL ^TMP($JOB,"AMIE1"),DVBADFN,DVBASITE,DVBADT,DVBAEA,DVBNM
+3 QUIT