XMA11A ;ISC-SF/GMB-Send/Answer a Message API ;04/18/2002 07:24
;;8.0;MailMan;;Jun 28, 2002
; Was (WASH ISC)/CAP/THM
;
; Entry points (DBIA 1233):
; WRITE Send a message or Answer a message
;
WRITE ; Send a message or Answer a message
; Needs:
; XMDUZ user number
; X if $E(X)="A", then send an answer, else send a message
; XMZ original message number, if we are sending an answer
N XMV
D INITAPI^XMVVITAE
I $E(X)'="A" D SEND^XMJMS Q
N XMZREC
S XMZREC=^XMB(3.9,XMZ,0)
K XMERR,^TMP("XMERR",$J)
I '$$ANSWER^XMXSEC(XMDUZ,XMZ,XMZREC) D SHOW^XMJERR Q
D ANSWER^XMJMA(XMDUZ,XMZ,$P(XMZREC,U,1),$P(XMZREC,U,2))
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HXMA11A 655 printed Oct 16, 2024@18:11:29 Page 2
XMA11A ;ISC-SF/GMB-Send/Answer a Message API ;04/18/2002 07:24
+1 ;;8.0;MailMan;;Jun 28, 2002
+2 ; Was (WASH ISC)/CAP/THM
+3 ;
+4 ; Entry points (DBIA 1233):
+5 ; WRITE Send a message or Answer a message
+6 ;
WRITE ; Send a message or Answer a message
+1 ; Needs:
+2 ; XMDUZ user number
+3 ; X if $E(X)="A", then send an answer, else send a message
+4 ; XMZ original message number, if we are sending an answer
+5 NEW XMV
+6 DO INITAPI^XMVVITAE
+7 IF $EXTRACT(X)'="A"
DO SEND^XMJMS
QUIT
+8 NEW XMZREC
+9 SET XMZREC=^XMB(3.9,XMZ,0)
+10 KILL XMERR,^TMP("XMERR",$JOB)
+11 IF '$$ANSWER^XMXSEC(XMDUZ,XMZ,XMZREC)
DO SHOW^XMJERR
QUIT
+12 DO ANSWER^XMJMA(XMDUZ,XMZ,$PIECE(XMZREC,U,1),$PIECE(XMZREC,U,2))
+13 QUIT