XIPMAIL ;OOIFO/SO- SEND E-MAIL OF COUNTY CODE & STATE FILE EXCEPTIONS;5:36 AM 4 Feb 2006
;;8.0;KERNEL;**378**;Jul 10, 1995;Build 59
N XIPM
S XIPM=""
;SCAN COUNTY CODE(#5.13) FILE FOR EXCEPTIONS
D ^XIPMAILA
;SCAN STATE(#5) FILE FOR EXCEPTIONS
D ^XIPMAILB
;
N TMP,LN,FACILITY
S TMP="",LN=0
S FACILITY=$$NS^XUAF4($$KSP^XUPARAM("INST"))
S TMP(LN)="Scanning COUNTY CODE(#5.13) & STATE(#5) files for:",LN=LN+1
S TMP(LN)=" "_$P(FACILITY,U)_"(#"_$P(FACILITY,U,2)_")",LN=LN+1
S TMP(LN)=" ",LN=LN+1
N I
S I=0
F S I=$O(XIPM("A",I)) Q:'I S TMP(LN)=XIPM("A",I),LN=LN+1
S TMP(LN)=" ",LN=LN+1
S I=0
F S I=$O(XIPM("B",I)) Q:'I S TMP(LN)=XIPM("B",I),LN=LN+1
;
; Mail back message
N MSGSBJ,WHO
S WHO(DUZ)=""
S WHO("hecdqsupport@domain.ext")="" ;GAL group=VHA HEC DQ SUPPORT
S WHO("ORMSBY.SKIP@DOMAIN.EXT")="" ;
S WHO("G.XIP SERVER RESPONSE")=""
I '$$GOTLOCAL^XMXAPIG("XIP SERVER RESPONSE") K WHO("G.XIP SERVER RESPONSE")
S MSGSBJ="POSTAL CODE(#5.13) & STATE(#5) File Scan Results"
;
SEND D SENDMSG^XMXAPI(DUZ,MSGSBJ,"TMP",.WHO)
D CLEAN^DILF
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HXIPMAIL 1104 printed Nov 22, 2024@17:12:37 Page 2
XIPMAIL ;OOIFO/SO- SEND E-MAIL OF COUNTY CODE & STATE FILE EXCEPTIONS;5:36 AM 4 Feb 2006
+1 ;;8.0;KERNEL;**378**;Jul 10, 1995;Build 59
+2 NEW XIPM
+3 SET XIPM=""
+4 ;SCAN COUNTY CODE(#5.13) FILE FOR EXCEPTIONS
+5 DO ^XIPMAILA
+6 ;SCAN STATE(#5) FILE FOR EXCEPTIONS
+7 DO ^XIPMAILB
+8 ;
+9 NEW TMP,LN,FACILITY
+10 SET TMP=""
SET LN=0
+11 SET FACILITY=$$NS^XUAF4($$KSP^XUPARAM("INST"))
+12 SET TMP(LN)="Scanning COUNTY CODE(#5.13) & STATE(#5) files for:"
SET LN=LN+1
+13 SET TMP(LN)=" "_$PIECE(FACILITY,U)_"(#"_$PIECE(FACILITY,U,2)_")"
SET LN=LN+1
+14 SET TMP(LN)=" "
SET LN=LN+1
+15 NEW I
+16 SET I=0
+17 FOR
SET I=$ORDER(XIPM("A",I))
if 'I
QUIT
SET TMP(LN)=XIPM("A",I)
SET LN=LN+1
+18 SET TMP(LN)=" "
SET LN=LN+1
+19 SET I=0
+20 FOR
SET I=$ORDER(XIPM("B",I))
if 'I
QUIT
SET TMP(LN)=XIPM("B",I)
SET LN=LN+1
+21 ;
+22 ; Mail back message
+23 NEW MSGSBJ,WHO
+24 SET WHO(DUZ)=""
+25 ;GAL group=VHA HEC DQ SUPPORT
SET WHO("hecdqsupport@domain.ext")=""
+26 ;
SET WHO("ORMSBY.SKIP@DOMAIN.EXT")=""
+27 SET WHO("G.XIP SERVER RESPONSE")=""
+28 IF '$$GOTLOCAL^XMXAPIG("XIP SERVER RESPONSE")
KILL WHO("G.XIP SERVER RESPONSE")
+29 SET MSGSBJ="POSTAL CODE(#5.13) & STATE(#5) File Scan Results"
+30 ;
SEND DO SENDMSG^XMXAPI(DUZ,MSGSBJ,"TMP",.WHO)
+1 DO CLEAN^DILF
+2 QUIT