ONCOX5 ; GENERATED FROM 'ONCOX5' PRINT TEMPLATE (#846) ; 08/13/03 ; (FILE 165.5, MARGIN=132)
G BEGIN
N W !
T W:$X ! I '$D(DIOT(2)),DN,$D(IOSL),$S('$D(DIWF):1,$P(DIWF,"B",2):$P(DIWF,"B",2),1:1)+$Y'<IOSL,$D(^UTILITY($J,1))#2,^(1)?1U1P1E.E X ^(1)
S DISTP=DISTP+1,DILCT=DILCT+1 D:'(DISTP#100) CSTP^DIO2
Q
DT I $G(DUZ("LANG"))>1,Y W $$OUT^DIALOGU(Y,"DD") Q
I Y W $P("JAN^FEB^MAR^APR^MAY^JUN^JUL^AUG^SEP^OCT^NOV^DEC",U,$E(Y,4,5))_" " W:Y#100 $J(Y#100\1,2)_"," W Y\10000+1700 W:Y#1 " "_$E(Y_0,9,10)_":"_$E(Y_"000",11,12) Q
W Y Q
M D @DIXX
Q
BEGIN ;
S:'$D(DN) DN=1 S DISTP=$G(DISTP),DILCT=$G(DILCT)
I $D(DXS)<9 M DXS=^DIPT(846,"DXS")
S I(0)="^ONCO(165.5,",J(0)=165.5
D T Q:'DN D N W ?0 X DXS(1,9) K DIP K:DN Y W X
D T Q:'DN D N D N:$X>14 Q:'DN W ?14 W "DX Date: "
S X=$G(^ONCO(165.5,D0,0)) S Y=$P(X,U,16) S Y(0)=Y S X=Y D DATEOT^ONCOES W $J(Y,13)
D N:$X>69 Q:'DN W ?69 W "Class of Case: "
X DXS(2,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>14 Q:'DN W ?14 W "Type of Reporting Source: "
X DXS(3,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>12 Q:'DN W ?12 W "Histology: "
S DIP(1)=$S($D(^ONCO(165.5,D0,2)):^(2),1:"") S X=$P(DIP(1),U,3),X=X K DIP K:DN Y W X
W " "
X DXS(4,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>71 Q:'DN W ?71 W "Dx Facility: "
X DXS(5,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>7 Q:'DN W ?7 W "Text Histology: "
X DXS(6,9) K DIP K:DN Y W X
D N:$X>16 Q:'DN W ?16 W "Grade:"
S X=$G(^ONCO(165.5,D0,2)) W ?24 S Y=$P(X,U,5) S Y(0)=Y S:Y'="" Y=$P(^ONCO(164.43,Y,0),U,1) W $E(Y,1,30)
S DIWL=57,DIWR=130 X DXS(7,9.2) S X=$P(DIP(101),U,2) S D0=I(0,0) K DIP K DIP K:DN Y D ^DIWP
D 0^DIWW
D ^DIWW
D T Q:'DN W ?2 S TM1=$$PRINT^ONCOTM(D0,1) K DIP K:DN Y
W ?13 W !?7,TM1_":" K DIP K:DN Y
S X=$G(^ONCO(165.5,D0,24)) W ?24 S Y=$P(X,U,2) S Y(0)=Y S Y=$P($G(^ONCO(164.15,+Y,0)),U,2) W $E(Y,1,30)
D N:$X>7 Q:'DN W ?7 W "Tumor Marker 2:"
S X=$G(^ONCO(165.5,D0,24)) W ?24 S Y=$P(X,U,3) S Y(0)=Y S Y=$P($G(^ONCO(164.15,+Y,0)),U,2) W $E(Y,1,30)
D T Q:'DN D N D N:$X>12 Q:'DN W ?12 W "ICDO-Site: "
X DXS(8,9.2) S X=$P(DIP(101),U,2) S D0=I(0,0) K DIP K:DN Y W X
W " "
X DXS(9,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>64 Q:'DN W ?64 W "Referring Facility: "
X DXS(10,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>11 Q:'DN W ?11 W "Laterality: "
X DXS(11,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>65 Q:'DN W ?65 W "Transfer Facility: "
X DXS(12,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>6 Q:'DN W ?6 W "DX Confirmation: "
X DXS(13,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>56 Q:'DN W ?56 W "Primary Payer at Diagnosis: "
X DXS(14,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
D N:$X>9 Q:'DN W ?9 W "IP/OP status: "
S X=$G(^ONCO(165.5,D0,0)) S Y=$P(X,U,23) W:Y]"" $S($D(DXS(18,Y)):DXS(18,Y),1:Y)
D N:$X>5 Q:'DN W ?5 W "Screening Result: "
S Y=$P(X,U,25) W:Y]"" $S($D(DXS(19,Y)):DXS(19,Y),1:Y)
D N:$X>68 Q:'DN W ?68 W "Screening Date: "
S Y=$P(X,U,24) S Y(0)=Y D DATEOT^ONCOPCE W $E(Y,1,30)
D N:$X>1 Q:'DN W ?1 W "Presentation at Cancer Conference: "
S X=$G(^ONCO(165.5,D0,0)) S Y=$P(X,U,26) W:Y]"" $S($D(DXS(20,Y)):DXS(20,Y),1:Y)
D N:$X>65 Q:'DN W ?65 W "Date of Cancer Conference: "
S Y=$P(X,U,27) S Y(0)=Y D DATEOT^ONCOPCE W $E(Y,1,30)
D N:$X>1 Q:'DN W ?1 W "Referral to Support Services: "
S X=$G(^ONCO(165.5,D0,0)) W ?34 S Y=$P(X,U,28) W:Y]"" $S($D(DXS(21,Y)):DXS(21,Y),1:Y)
D T Q:'DN D N D N:$X>14 Q:'DN W ?14 W "Site/Gp: "
X DXS(15,9.2) X "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)" K DIP K:DN Y W X
W " Primary Sequence No: "
S X=$G(^ONCO(165.5,D0,0)) W ?0,$E($P(X,U,6),1,2)
D N:$X>4 Q:'DN W ?4 W "Text-Primary Site Title: "
X DXS(16,9) K DIP K:DN Y W X
D N:$X>6 Q:'DN W ?6 W " "
D N:$X>4 Q:'DN W ?4 W "Text-Dx Proc-PE: "
S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=10,J(1)=165.5104 F D1=0:0 Q:$O(^ONCO(165.5,D0,10,D1))'>0 S D1=$O(^(D1)) D:$X>23 T Q:'DN D A1
G A1R
A1 ;
S X=$G(^ONCO(165.5,D0,10,D1,0)) S DIWL=24,DIWR=130 D ^DIWP
Q
A1R ;
D 0^DIWW
D ^DIWW
D N:$X>4 Q:'DN W ?4 W "Text-Dx Proc-X-ray/scan: "
S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=11,J(1)=165.5105 F D1=0:0 Q:$O(^ONCO(165.5,D0,11,D1))'>0 S D1=$O(^(D1)) D:$X>31 T Q:'DN D B1
G B1R
B1 ;
S X=$G(^ONCO(165.5,D0,11,D1,0)) S DIWL=32,DIWR=130 D ^DIWP
Q
B1R ;
D 0^DIWW
D ^DIWW
D N:$X>4 Q:'DN W ?4 W "Text-Dx Proc-Op: "
S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=9,J(1)=165.5103 F D1=0:0 Q:$O(^ONCO(165.5,D0,9,D1))'>0 S D1=$O(^(D1)) D:$X>23 T Q:'DN D C1
G C1R
C1 ;
S X=$G(^ONCO(165.5,D0,9,D1,0)) S DIWL=24,DIWR=130 D ^DIWP
Q
C1R ;
D 0^DIWW
D ^DIWW
D N:$X>4 Q:'DN W ?4 W "Text-Dx Proc-Lab Tests: "
S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=22,J(1)=165.5116 F D1=0:0 Q:$O(^ONCO(165.5,D0,22,D1))'>0 S D1=$O(^(D1)) D:$X>30 T Q:'DN D D1
G D1R
D1 ;
S X=$G(^ONCO(165.5,D0,22,D1,0)) S DIWL=31,DIWR=130 D ^DIWP
Q
D1R ;
D 0^DIWW
D ^DIWW
D N:$X>4 Q:'DN W ?4 W "Text-Dx Proc-Scopes: "
S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=12,J(1)=165.5106 F D1=0:0 Q:$O(^ONCO(165.5,D0,12,D1))'>0 S D1=$O(^(D1)) D:$X>27 T Q:'DN D E1
G E1R
E1 ;
S X=$G(^ONCO(165.5,D0,12,D1,0)) S DIWL=28,DIWR=130 D ^DIWP
Q
E1R ;
D 0^DIWW
D ^DIWW
D N:$X>4 Q:'DN W ?4 W "Text-Dx Proc-Path: "
S:'$D(DIWF) DIWF="" S:DIWF'["N" DIWF=DIWF_"N" S X="" S I(1)=13,J(1)=165.5107 F D1=0:0 Q:$O(^ONCO(165.5,D0,13,D1))'>0 S D1=$O(^(D1)) D:$X>25 T Q:'DN D F1
G F1R
F1 ;
S X=$G(^ONCO(165.5,D0,13,D1,0)) S DIWL=26,DIWR=130 D ^DIWP
Q
F1R ;
D 0^DIWW
D ^DIWW
D T Q:'DN D N W ?0 X DXS(17,9) K DIP K:DN Y W X
D T Q:'DN D N W ?0 S X="" D SDP^ONCOCOM W $E(X,1,80) K Y(165.5,48)
K Y K DIWF
Q
HEAD ;
W !,"------------------------------------------------------------------------------------------------------------------------------------",!!
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HONCOX5 6709 printed Nov 22, 2024@17:36:22 Page 2
ONCOX5 ; GENERATED FROM 'ONCOX5' PRINT TEMPLATE (#846) ; 08/13/03 ; (FILE 165.5, MARGIN=132)
+1 GOTO BEGIN
N WRITE !
T if $X
WRITE !
IF '$DATA(DIOT(2))
IF DN
IF $DATA(IOSL)
IF $SELECT('$DATA(DIWF):1,$PIECE(DIWF,"B",2):$PIECE(DIWF,"B",2),1:1)+$Y'<IOSL
IF $DATA(^UTILITY($JOB,1))#2
IF ^(1)?1U1P1E.E
XECUTE ^(1)
+1 SET DISTP=DISTP+1
SET DILCT=DILCT+1
if '(DISTP#100)
DO CSTP^DIO2
+2 QUIT
DT IF $GET(DUZ("LANG"))>1
IF Y
WRITE $$OUT^DIALOGU(Y,"DD")
QUIT
+1 IF Y
WRITE $PIECE("JAN^FEB^MAR^APR^MAY^JUN^JUL^AUG^SEP^OCT^NOV^DEC",U,$EXTRACT(Y,4,5))_" "
if Y#100
WRITE $JUSTIFY(Y#100\1,2)_","
WRITE Y\10000+1700
if Y#1
WRITE " "_$EXTRACT(Y_0,9,10)_":"_$EXTRACT(Y_"000",11,12)
QUIT
+2 WRITE Y
QUIT
M DO @DIXX
+1 QUIT
BEGIN ;
+1 if '$DATA(DN)
SET DN=1
SET DISTP=$GET(DISTP)
SET DILCT=$GET(DILCT)
+2 IF $DATA(DXS)<9
MERGE DXS=^DIPT(846,"DXS")
+3 SET I(0)="^ONCO(165.5,"
SET J(0)=165.5
+4 DO T
if 'DN
QUIT
DO N
WRITE ?0
XECUTE DXS(1,9)
KILL DIP
if DN
KILL Y
WRITE X
+5 DO T
if 'DN
QUIT
DO N
if $X>14
DO N
if 'DN
QUIT
WRITE ?14
WRITE "DX Date: "
+6 SET X=$GET(^ONCO(165.5,D0,0))
SET Y=$PIECE(X,U,16)
SET Y(0)=Y
SET X=Y
DO DATEOT^ONCOES
WRITE $JUSTIFY(Y,13)
+7 if $X>69
DO N
if 'DN
QUIT
WRITE ?69
WRITE "Class of Case: "
+8 XECUTE DXS(2,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+9 if $X>14
DO N
if 'DN
QUIT
WRITE ?14
WRITE "Type of Reporting Source: "
+10 XECUTE DXS(3,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+11 if $X>12
DO N
if 'DN
QUIT
WRITE ?12
WRITE "Histology: "
+12 SET DIP(1)=$SELECT($DATA(^ONCO(165.5,D0,2)):^(2),1:"")
SET X=$PIECE(DIP(1),U,3)
SET X=X
KILL DIP
if DN
KILL Y
WRITE X
+13 WRITE " "
+14 XECUTE DXS(4,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+15 if $X>71
DO N
if 'DN
QUIT
WRITE ?71
WRITE "Dx Facility: "
+16 XECUTE DXS(5,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+17 if $X>7
DO N
if 'DN
QUIT
WRITE ?7
WRITE "Text Histology: "
+18 XECUTE DXS(6,9)
KILL DIP
if DN
KILL Y
WRITE X
+19 if $X>16
DO N
if 'DN
QUIT
WRITE ?16
WRITE "Grade:"
+20 SET X=$GET(^ONCO(165.5,D0,2))
WRITE ?24
SET Y=$PIECE(X,U,5)
SET Y(0)=Y
if Y'=""
SET Y=$PIECE(^ONCO(164.43,Y,0),U,1)
WRITE $EXTRACT(Y,1,30)
+21 SET DIWL=57
SET DIWR=130
XECUTE DXS(7,9.2)
SET X=$PIECE(DIP(101),U,2)
SET D0=I(0,0)
KILL DIP
KILL DIP
if DN
KILL Y
DO ^DIWP
+22 DO 0^DIWW
+23 DO ^DIWW
+24 DO T
if 'DN
QUIT
WRITE ?2
SET TM1=$$PRINT^ONCOTM(D0,1)
KILL DIP
if DN
KILL Y
+25 WRITE ?13
WRITE !?7,TM1_":"
KILL DIP
if DN
KILL Y
+26 SET X=$GET(^ONCO(165.5,D0,24))
WRITE ?24
SET Y=$PIECE(X,U,2)
SET Y(0)=Y
SET Y=$PIECE($GET(^ONCO(164.15,+Y,0)),U,2)
WRITE $EXTRACT(Y,1,30)
+27 if $X>7
DO N
if 'DN
QUIT
WRITE ?7
WRITE "Tumor Marker 2:"
+28 SET X=$GET(^ONCO(165.5,D0,24))
WRITE ?24
SET Y=$PIECE(X,U,3)
SET Y(0)=Y
SET Y=$PIECE($GET(^ONCO(164.15,+Y,0)),U,2)
WRITE $EXTRACT(Y,1,30)
+29 DO T
if 'DN
QUIT
DO N
if $X>12
DO N
if 'DN
QUIT
WRITE ?12
WRITE "ICDO-Site: "
+30 XECUTE DXS(8,9.2)
SET X=$PIECE(DIP(101),U,2)
SET D0=I(0,0)
KILL DIP
if DN
KILL Y
WRITE X
+31 WRITE " "
+32 XECUTE DXS(9,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+33 if $X>64
DO N
if 'DN
QUIT
WRITE ?64
WRITE "Referring Facility: "
+34 XECUTE DXS(10,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+35 if $X>11
DO N
if 'DN
QUIT
WRITE ?11
WRITE "Laterality: "
+36 XECUTE DXS(11,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+37 if $X>65
DO N
if 'DN
QUIT
WRITE ?65
WRITE "Transfer Facility: "
+38 XECUTE DXS(12,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+39 if $X>6
DO N
if 'DN
QUIT
WRITE ?6
WRITE "DX Confirmation: "
+40 XECUTE DXS(13,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+41 if $X>56
DO N
if 'DN
QUIT
WRITE ?56
WRITE "Primary Payer at Diagnosis: "
+42 XECUTE DXS(14,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+43 if $X>9
DO N
if 'DN
QUIT
WRITE ?9
WRITE "IP/OP status: "
+44 SET X=$GET(^ONCO(165.5,D0,0))
SET Y=$PIECE(X,U,23)
if Y]""
WRITE $SELECT($DATA(DXS(18,Y)):DXS(18,Y),1:Y)
+45 if $X>5
DO N
if 'DN
QUIT
WRITE ?5
WRITE "Screening Result: "
+46 SET Y=$PIECE(X,U,25)
if Y]""
WRITE $SELECT($DATA(DXS(19,Y)):DXS(19,Y),1:Y)
+47 if $X>68
DO N
if 'DN
QUIT
WRITE ?68
WRITE "Screening Date: "
+48 SET Y=$PIECE(X,U,24)
SET Y(0)=Y
DO DATEOT^ONCOPCE
WRITE $EXTRACT(Y,1,30)
+49 if $X>1
DO N
if 'DN
QUIT
WRITE ?1
WRITE "Presentation at Cancer Conference: "
+50 SET X=$GET(^ONCO(165.5,D0,0))
SET Y=$PIECE(X,U,26)
if Y]""
WRITE $SELECT($DATA(DXS(20,Y)):DXS(20,Y),1:Y)
+51 if $X>65
DO N
if 'DN
QUIT
WRITE ?65
WRITE "Date of Cancer Conference: "
+52 SET Y=$PIECE(X,U,27)
SET Y(0)=Y
DO DATEOT^ONCOPCE
WRITE $EXTRACT(Y,1,30)
+53 if $X>1
DO N
if 'DN
QUIT
WRITE ?1
WRITE "Referral to Support Services: "
+54 SET X=$GET(^ONCO(165.5,D0,0))
WRITE ?34
SET Y=$PIECE(X,U,28)
if Y]""
WRITE $SELECT($DATA(DXS(21,Y)):DXS(21,Y),1:Y)
+55 DO T
if 'DN
QUIT
DO N
if $X>14
DO N
if 'DN
QUIT
WRITE ?14
WRITE "Site/Gp: "
+56 XECUTE DXS(15,9.2)
XECUTE "F %=2:1:$L(X) I $E(X,%)?1U,$E(X,%-1)?1A S X=$E(X,0,%-1)_$C($A(X,%)+32)_$E(X,%+1,999)"
KILL DIP
if DN
KILL Y
WRITE X
+57 WRITE " Primary Sequence No: "
+58 SET X=$GET(^ONCO(165.5,D0,0))
WRITE ?0,$EXTRACT($PIECE(X,U,6),1,2)
+59 if $X>4
DO N
if 'DN
QUIT
WRITE ?4
WRITE "Text-Primary Site Title: "
+60 XECUTE DXS(16,9)
KILL DIP
if DN
KILL Y
WRITE X
+61 if $X>6
DO N
if 'DN
QUIT
WRITE ?6
WRITE " "
+62 if $X>4
DO N
if 'DN
QUIT
WRITE ?4
WRITE "Text-Dx Proc-PE: "
+63 if '$DATA(DIWF)
SET DIWF=""
if DIWF'["N"
SET DIWF=DIWF_"N"
SET X=""
SET I(1)=10
SET J(1)=165.5104
FOR D1=0:0
if $ORDER(^ONCO(165.5,D0,10,D1))'>0
QUIT
SET D1=$ORDER(^(D1))
if $X>23
DO T
if 'DN
QUIT
DO A1
+64 GOTO A1R
A1 ;
+1 SET X=$GET(^ONCO(165.5,D0,10,D1,0))
SET DIWL=24
SET DIWR=130
DO ^DIWP
+2 QUIT
A1R ;
+1 DO 0^DIWW
+2 DO ^DIWW
+3 if $X>4
DO N
if 'DN
QUIT
WRITE ?4
WRITE "Text-Dx Proc-X-ray/scan: "
+4 if '$DATA(DIWF)
SET DIWF=""
if DIWF'["N"
SET DIWF=DIWF_"N"
SET X=""
SET I(1)=11
SET J(1)=165.5105
FOR D1=0:0
if $ORDER(^ONCO(165.5,D0,11,D1))'>0
QUIT
SET D1=$ORDER(^(D1))
if $X>31
DO T
if 'DN
QUIT
DO B1
+5 GOTO B1R
B1 ;
+1 SET X=$GET(^ONCO(165.5,D0,11,D1,0))
SET DIWL=32
SET DIWR=130
DO ^DIWP
+2 QUIT
B1R ;
+1 DO 0^DIWW
+2 DO ^DIWW
+3 if $X>4
DO N
if 'DN
QUIT
WRITE ?4
WRITE "Text-Dx Proc-Op: "
+4 if '$DATA(DIWF)
SET DIWF=""
if DIWF'["N"
SET DIWF=DIWF_"N"
SET X=""
SET I(1)=9
SET J(1)=165.5103
FOR D1=0:0
if $ORDER(^ONCO(165.5,D0,9,D1))'>0
QUIT
SET D1=$ORDER(^(D1))
if $X>23
DO T
if 'DN
QUIT
DO C1
+5 GOTO C1R
C1 ;
+1 SET X=$GET(^ONCO(165.5,D0,9,D1,0))
SET DIWL=24
SET DIWR=130
DO ^DIWP
+2 QUIT
C1R ;
+1 DO 0^DIWW
+2 DO ^DIWW
+3 if $X>4
DO N
if 'DN
QUIT
WRITE ?4
WRITE "Text-Dx Proc-Lab Tests: "
+4 if '$DATA(DIWF)
SET DIWF=""
if DIWF'["N"
SET DIWF=DIWF_"N"
SET X=""
SET I(1)=22
SET J(1)=165.5116
FOR D1=0:0
if $ORDER(^ONCO(165.5,D0,22,D1))'>0
QUIT
SET D1=$ORDER(^(D1))
if $X>30
DO T
if 'DN
QUIT
DO D1
+5 GOTO D1R
D1 ;
+1 SET X=$GET(^ONCO(165.5,D0,22,D1,0))
SET DIWL=31
SET DIWR=130
DO ^DIWP
+2 QUIT
D1R ;
+1 DO 0^DIWW
+2 DO ^DIWW
+3 if $X>4
DO N
if 'DN
QUIT
WRITE ?4
WRITE "Text-Dx Proc-Scopes: "
+4 if '$DATA(DIWF)
SET DIWF=""
if DIWF'["N"
SET DIWF=DIWF_"N"
SET X=""
SET I(1)=12
SET J(1)=165.5106
FOR D1=0:0
if $ORDER(^ONCO(165.5,D0,12,D1))'>0
QUIT
SET D1=$ORDER(^(D1))
if $X>27
DO T
if 'DN
QUIT
DO E1
+5 GOTO E1R
E1 ;
+1 SET X=$GET(^ONCO(165.5,D0,12,D1,0))
SET DIWL=28
SET DIWR=130
DO ^DIWP
+2 QUIT
E1R ;
+1 DO 0^DIWW
+2 DO ^DIWW
+3 if $X>4
DO N
if 'DN
QUIT
WRITE ?4
WRITE "Text-Dx Proc-Path: "
+4 if '$DATA(DIWF)
SET DIWF=""
if DIWF'["N"
SET DIWF=DIWF_"N"
SET X=""
SET I(1)=13
SET J(1)=165.5107
FOR D1=0:0
if $ORDER(^ONCO(165.5,D0,13,D1))'>0
QUIT
SET D1=$ORDER(^(D1))
if $X>25
DO T
if 'DN
QUIT
DO F1
+5 GOTO F1R
F1 ;
+1 SET X=$GET(^ONCO(165.5,D0,13,D1,0))
SET DIWL=26
SET DIWR=130
DO ^DIWP
+2 QUIT
F1R ;
+1 DO 0^DIWW
+2 DO ^DIWW
+3 DO T
if 'DN
QUIT
DO N
WRITE ?0
XECUTE DXS(17,9)
KILL DIP
if DN
KILL Y
WRITE X
+4 DO T
if 'DN
QUIT
DO N
WRITE ?0
SET X=""
DO SDP^ONCOCOM
WRITE $EXTRACT(X,1,80)
KILL Y(165.5,48)
+5 KILL Y
KILL DIWF
+6 QUIT
HEAD ;
+1 WRITE !,"------------------------------------------------------------------------------------------------------------------------------------",!!