ONCTPC8 ;Hines OIFO/GWB -PCE Study of Thyroid Cancer ;05/30/00
;;2.2;ONCOLOGY;**1**;Jul 31, 2013;Build 8
;Print
K IOP,%ZIS S %ZIS="MQ" W ! D ^%ZIS K %ZIS,IOP G:POP KILL
I $D(IO("Q")) S ONCOLST="ONCONUM^ONCOPA^PATNAM^SPACES^TOPNAM^SSN^TOPTAB^TOPCOD^DASHES^SITTAB^SITEGP" D TASK G KILL
U IO D PRT D ^%ZISC K %ZIS,IOP G KILL
PRT S PG=0,EX="",LIN=$S(IOST?1"C".E:IOSL-2,1:IOSL-6),IEN=ONCONUM
D NOW^%DTC S ONDATE=%,Y=ONDATE X ^DD("DD") S ONDATE=Y
K DIQ S DIC="^ONCO(160,",DR="9;15;22.9",DA=ONCOPA,DIQ="ONC" D EN^DIQ1
S DR=".04;.05;.06;.1;.12;3;9;18;20;22;24;26;29;32;33;34;34.1;34.2;37.1;37.2;37.3;38;19;50;51;51.2;53.2;54.2;58.1;58.2;58.3;59;70;71;71.1;71.2;71.3;71.4;81;82;85;86;87;88;89;308;400:446"
S DIC="^ONCO(165.5,",DA=ONCONUM,DIQ="ONC" D EN^DIQ1
I S TABLE="TABLE I - GENERAL INFORMATION"
D HDR W !?25,TABLE,!
S D0=ONCOPA D DOB1^ONCOES S Y=X D DATEOT^ONCOPCE S DOB=Y
W !,"ACCESSION NUMBER..................: ",ONC(165.5,IEN,.05) D P Q:EX=U
W !,"SEQUENCE NUMBER...................: ",ONC(165.5,IEN,.06) D P Q:EX=U
W !,"POSTAL CODE AT DIAGNOSIS..........: ",ONC(165.5,IEN,9) D P Q:EX=U
W !,"DATE OF BIRTH.....................: ",DOB D P Q:EX=U
W !,"RACE..............................: ",ONC(165.5,IEN,.12) D P Q:EX=U
W !,"SPANISH ORIGIN....................: ",ONC(160,ONCOPA,9) D P Q:EX=U
W !,"SEX...............................: ",ONC(165.5,IEN,.1) D P Q:EX=U
W !,"PRIMARY PAYER AT DIAGNOSIS........: ",ONC(165.5,IEN,18) D P Q:EX=U
W !,"FAMILY HISTORY OF THYROID CANCER..: ",ONC(165.5,IEN,400)
I IOST?1"C".E W ! K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR W !?15,TABLE_" (continued)" G PHNTC
D P Q:EX=U
PHNTC W !!,"PERSONAL HISTORY OF NON-THYROID CANCER:" D P Q:EX=U
W ! D P Q:EX=U
W !," LYMPHOMA........................: ",ONC(165.5,IEN,401) D P Q:EX=U
W !," CHILDHOOD MALIGNANCY............: ",ONC(165.5,IEN,402) D P Q:EX=U
W !," OTHER...........................: ",ONC(165.5,IEN,308) D P Q:EX=U
W ! D P Q:EX=U
W !,"PRIOR EXPOSURE TO RADIATION.......: ",ONC(165.5,IEN,403) D P Q:EX=U
W !,"PERSONAL HISTORY OF GOITER........: ",ONC(165.5,IEN,404) D P Q:EX=U
W !,"FAMILY HISTORY OF THYROID DISEASE.: ",ONC(165.5,IEN,405) D P Q:EX=U
W !,"PERSONAL HISTORY OF GRAVES DISEASE: ",ONC(165.5,IEN,406) D P Q:EX=U
W !,"PERSONAL HISTORY OF THYROIDITIS...: ",ONC(165.5,IEN,406)
I IOST?1"C".E W ! K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR G II
D P Q:EX=U
II S TABLE="TABLE II - INITIAL DIAGNOSIS/CANCER IDENTIFICATION"
I IOST'?1"C".E W ! I ($Y'<(LIN-4)) D HDR
W !?15,TABLE,! D P Q:EX=U
W !,"CLASS OF CASE.....................: ",ONC(165.5,IEN,.04) D P Q:EX=U
W !!,"SYMPTOMS/SIGNS PRESENT:",! D P Q:EX=U
W !," DYSPHAGIA.......................: ",ONC(165.5,IEN,408) D P Q:EX=U
W !," HOARSENESS OR VOICE CHANGE......: ",ONC(165.5,IEN,409) D P Q:EX=U
W !," NECK NODAL MASS.................: ",ONC(165.5,IEN,410) D P Q:EX=U
W !," PAIN, BONE......................: ",ONC(165.5,IEN,411) D P Q:EX=U
W !," PAIN, NECK......................: ",ONC(165.5,IEN,412) D P Q:EX=U
W !," PATHOLOGIC FRACTURE.............: ",ONC(165.5,IEN,413) D P Q:EX=U
W !," STRIDOR/DIFFICULTY BREATHING....: ",ONC(165.5,IEN,414) D P Q:EX=U
W !," THYROID MASS....................: ",ONC(165.5,IEN,415) D P Q:EX=U
W !," WEIGHT LOSS.....................: ",ONC(165.5,IEN,416) D P Q:EX=U
W !," OTHER...........................: ",ONC(165.5,IEN,417)
I IOST?1"C".E W ! K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR W !?15,TABLE_" (continued)" G DSW
D P Q:EX=U
DSW W !!,"DIAGNOISTIC/SURGICAL WORKUP:",! D P Q:EX=U
W !," BONE SCAN.......................: ",ONC(165.5,IEN,418) D P Q:EX=U
W !," CHEST X-RAY.....................: ",ONC(165.5,IEN,419) D P Q:EX=U
W !," CT SCAN OF NECK.................: ",ONC(165.5,IEN,420) D P Q:EX=U
W !," CT SCAN OF CHEST................: ",ONC(165.5,IEN,421) D P Q:EX=U
W !," INCISIONAL BIOPSY...............: ",ONC(165.5,IEN,422) D P Q:EX=U
W !," LARYNGOSCOPY....................: ",ONC(165.5,IEN,423) D P Q:EX=U
W !," NECK X-RAY (AP & LATERAL........: ",ONC(165.5,IEN,424) D P Q:EX=U
W !," NEEDLE ASPIRATION OF NECK NODE..: ",ONC(165.5,IEN,425) D P Q:EX=U
W !," NEEDLE ASPIRATION OF THYROID....: ",ONC(165.5,IEN,426) D P Q:EX=U
W !," MRI OF NECK.....................: ",ONC(165.5,IEN,427) D P Q:EX=U
W !," THYROID SCAN....................: ",ONC(165.5,IEN,428) D P Q:EX=U
W !," ULTRASOUND OF THYROID...........: ",ONC(165.5,IEN,429) D P Q:EX=U
W !," OTHER...........................: ",ONC(165.5,IEN,430)
I IOST?1"C".E K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR W !?15,TABLE_" (continued)" G DOID
D P Q:EX=U
DOID W !!,"DATE OF INITIAL DIAGNOSIS.........: ",ONC(165.5,IEN,3) D P Q:EX=U
W !,"PRIMARY SITE (ICD-O-2)............: ",TOPCOD," ",ONC(165.5,IEN,20)
W !,"HISTOLOGY/BEHAVIOR CODE (ICD-O-2).: ",ONC(165.5,IEN,22) D P Q:EX=U
W !,"GRADE.............................: ",ONC(165.5,IEN,24) D P Q:EX=U
W !,"BLOOD VESSEL INVASION.............: ",ONC(165.5,IEN,431) D P Q:EX=U
W !,"EXTRA-THYROIDAL EXTENSION.........: ",ONC(165.5,IEN,432) D P Q:EX=U
W !,"DIAGNOSTIC CONFIRMATION...........: ",ONC(165.5,IEN,26)
I IOST?1"C".E W ! K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR G III
D P Q:EX=U
III S TABLE="TABLE III - EXTENT OF DISEASE AND AJCC STAGE"
I IOST'?1"C".E W ! I ($Y'<(LIN-4)) D HDR
W !?15,TABLE,! D P Q:EX=U
W !,"SIZE OF TUMOR (mm)................: ",ONC(165.5,IEN,29) D P Q:EX=U
W !,"MULTIFOCAL........................: ",ONC(165.5,IEN,433) D P Q:EX=U
W !,"REGIONAL NODES EXAMINED...........: ",ONC(165.5,IEN,33) D P Q:EX=U
W !,"REGIONAL NODES POSITIVE...........: ",ONC(165.5,IEN,32) D P Q:EX=U
W !,"LOCATION OF POSITIVE NODES........: ",ONC(165.5,IEN,434) D P Q:EX=U
W !!,"SITE(S) OF DISTANT METASTASIS:",! D P Q:EX=U
W !," SITE OF DISTANT METASTASIS #1...: ",ONC(165.5,IEN,34) D P Q:EX=U
W !," SITE OF DISTANT METASTASIS #2...: ",ONC(165.5,IEN,34.1) D P Q:EX=U
W !," SITE OF DISTANT METASTASIS #3...: ",ONC(165.5,IEN,34.2)
I IOST?1"C".E W ! K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR W !?15,TABLE_" (continued)" G AJCCCS
D P Q:EX=U
AJCCCS W !!,"AJCC CLINICAL STAGE (cTNM):",! D P Q:EX=U
W !," T-CODE........................: ",ONC(165.5,IEN,37.1) D P Q:EX=U
W !," N-CODE........................: ",ONC(165.5,IEN,37.2) D P Q:EX=U
W !," M-CODE........................: ",ONC(165.5,IEN,37.3) D P Q:EX=U
W !," AJCC STAGE....................: ",ONC(165.5,IEN,38) D P Q:EX=U
AJCCPS W !!,"AJCC PATHOLOGIC STAGE (pTNM):",! D P Q:EX=U
W !," T-CODE........................: ",ONC(165.5,IEN,85) D P Q:EX=U
W !," N-CODE........................: ",ONC(165.5,IEN,86) D P Q:EX=U
W !," M-CODE........................: ",ONC(165.5,IEN,87) D P Q:EX=U
W !," AJCC STAGE....................: ",ONC(165.5,IEN,88)
I IOST?1"C".E W ! K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR W !?15,TABLE_" (continued)" G SB
D P Q:EX=U
SB W !!,"STAGED BY:",! D P Q:EX=U
W !," CLINICAL STAGE................: ",ONC(165.5,IEN,19) D P Q:EX=U
W !," PATHOLOGIC STAGE..............: ",ONC(165.5,IEN,89)
I IOST?1"C".E W ! K DIR S DIR(0)="E" D ^DIR Q:'Y D HDR G IV
D P Q:EX=U
IV D ^ONCTPC8A
KILL ;Kill Variables and Exit
K CDS,CDSOT,CS,CSDAT,CSIEN,CSPNT,DLC,DOB,DOIT,FIL,LIN,LOS,NCDS
K NCDSIEN,NCDSOT,ONC,ONDATE,PG,SURG,SURG1,SURG2,SURGDT,TABLE
K %,DIR,DIROUT,DIRUT,DTOUT,DUOUT,X,Y
Q
P ;Print
I ($Y'<(LIN-1)) D Q:EX=U W !?15,TABLE_" (continued)",!
.I IOST?1"C".E K DIR S DIR(0)="E" D ^DIR I 'Y S EX=U Q
.D HDR Q
Q
TASK ;Queue a task
K IO("Q"),ZTUCI,ZTDTH,ZTIO,ZTSAVE
S ZTRTN="PRT^ONCTPC8",ZTREQ="@",ZTSAVE("ZTREQ")=""
S ZTDESC="Print Thyroid PCE"
F V2=1:1 S V1=$P(ONCOLST,"^",V2) Q:V1="" S ZTSAVE(V1)=""
D ^%ZTLOAD D ^%ZISC U IO W !,"Request Queued",!
K V1,V2,ONCOLST,ZTSK Q
HDR ;Header
W @IOF S PG=PG+1 N BLANKS S $P(BLANKS," ",SITTAB-$L(PATNAM)-4)=" "
W " ",PATNAM,BLANKS,SITEGP,!,?1,SSN,?TOPTAB-3,TOPNAM," ",TOPCOD
W $S($L(PG)=2:" ",1:" "),PG,!,DASHES
W !?20," PCE Study of Thyroid Cancer"
W ?59,ONDATE,!,DASHES
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HONCTPC8 8022 printed Dec 13, 2024@02:29:06 Page 2
ONCTPC8 ;Hines OIFO/GWB -PCE Study of Thyroid Cancer ;05/30/00
+1 ;;2.2;ONCOLOGY;**1**;Jul 31, 2013;Build 8
+2 ;Print
+3 KILL IOP,%ZIS
SET %ZIS="MQ"
WRITE !
DO ^%ZIS
KILL %ZIS,IOP
if POP
GOTO KILL
+4 IF $DATA(IO("Q"))
SET ONCOLST="ONCONUM^ONCOPA^PATNAM^SPACES^TOPNAM^SSN^TOPTAB^TOPCOD^DASHES^SITTAB^SITEGP"
DO TASK
GOTO KILL
+5 USE IO
DO PRT
DO ^%ZISC
KILL %ZIS,IOP
GOTO KILL
PRT SET PG=0
SET EX=""
SET LIN=$SELECT(IOST?1"C".E:IOSL-2,1:IOSL-6)
SET IEN=ONCONUM
+1 DO NOW^%DTC
SET ONDATE=%
SET Y=ONDATE
XECUTE ^DD("DD")
SET ONDATE=Y
+2 KILL DIQ
SET DIC="^ONCO(160,"
SET DR="9;15;22.9"
SET DA=ONCOPA
SET DIQ="ONC"
DO EN^DIQ1
+3 SET DR=".04;.05;.06;.1;.12;3;9;18;20;22;24;26;29;32;33;34;34.1;34.2;37.1;37.2;37.3;38;19;50;51;51.2;53.2;54.2;58.1;58.2;58.3;59;70;71;71.1;71.2;71.3;71.4;81;82;85;86;87;88;89;308;400:446"
+4 SET DIC="^ONCO(165.5,"
SET DA=ONCONUM
SET DIQ="ONC"
DO EN^DIQ1
I SET TABLE="TABLE I - GENERAL INFORMATION"
+1 DO HDR
WRITE !?25,TABLE,!
+2 SET D0=ONCOPA
DO DOB1^ONCOES
SET Y=X
DO DATEOT^ONCOPCE
SET DOB=Y
+3 WRITE !,"ACCESSION NUMBER..................: ",ONC(165.5,IEN,.05)
DO P
if EX=U
QUIT
+4 WRITE !,"SEQUENCE NUMBER...................: ",ONC(165.5,IEN,.06)
DO P
if EX=U
QUIT
+5 WRITE !,"POSTAL CODE AT DIAGNOSIS..........: ",ONC(165.5,IEN,9)
DO P
if EX=U
QUIT
+6 WRITE !,"DATE OF BIRTH.....................: ",DOB
DO P
if EX=U
QUIT
+7 WRITE !,"RACE..............................: ",ONC(165.5,IEN,.12)
DO P
if EX=U
QUIT
+8 WRITE !,"SPANISH ORIGIN....................: ",ONC(160,ONCOPA,9)
DO P
if EX=U
QUIT
+9 WRITE !,"SEX...............................: ",ONC(165.5,IEN,.1)
DO P
if EX=U
QUIT
+10 WRITE !,"PRIMARY PAYER AT DIAGNOSIS........: ",ONC(165.5,IEN,18)
DO P
if EX=U
QUIT
+11 WRITE !,"FAMILY HISTORY OF THYROID CANCER..: ",ONC(165.5,IEN,400)
+12 IF IOST?1"C".E
WRITE !
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
WRITE !?15,TABLE_" (continued)"
GOTO PHNTC
+13 DO P
if EX=U
QUIT
PHNTC WRITE !!,"PERSONAL HISTORY OF NON-THYROID CANCER:"
DO P
if EX=U
QUIT
+1 WRITE !
DO P
if EX=U
QUIT
+2 WRITE !," LYMPHOMA........................: ",ONC(165.5,IEN,401)
DO P
if EX=U
QUIT
+3 WRITE !," CHILDHOOD MALIGNANCY............: ",ONC(165.5,IEN,402)
DO P
if EX=U
QUIT
+4 WRITE !," OTHER...........................: ",ONC(165.5,IEN,308)
DO P
if EX=U
QUIT
+5 WRITE !
DO P
if EX=U
QUIT
+6 WRITE !,"PRIOR EXPOSURE TO RADIATION.......: ",ONC(165.5,IEN,403)
DO P
if EX=U
QUIT
+7 WRITE !,"PERSONAL HISTORY OF GOITER........: ",ONC(165.5,IEN,404)
DO P
if EX=U
QUIT
+8 WRITE !,"FAMILY HISTORY OF THYROID DISEASE.: ",ONC(165.5,IEN,405)
DO P
if EX=U
QUIT
+9 WRITE !,"PERSONAL HISTORY OF GRAVES DISEASE: ",ONC(165.5,IEN,406)
DO P
if EX=U
QUIT
+10 WRITE !,"PERSONAL HISTORY OF THYROIDITIS...: ",ONC(165.5,IEN,406)
+11 IF IOST?1"C".E
WRITE !
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
GOTO II
+12 DO P
if EX=U
QUIT
II SET TABLE="TABLE II - INITIAL DIAGNOSIS/CANCER IDENTIFICATION"
+1 IF IOST'?1"C".E
WRITE !
IF ($Y'<(LIN-4))
DO HDR
+2 WRITE !?15,TABLE,!
DO P
if EX=U
QUIT
+3 WRITE !,"CLASS OF CASE.....................: ",ONC(165.5,IEN,.04)
DO P
if EX=U
QUIT
+4 WRITE !!,"SYMPTOMS/SIGNS PRESENT:",!
DO P
if EX=U
QUIT
+5 WRITE !," DYSPHAGIA.......................: ",ONC(165.5,IEN,408)
DO P
if EX=U
QUIT
+6 WRITE !," HOARSENESS OR VOICE CHANGE......: ",ONC(165.5,IEN,409)
DO P
if EX=U
QUIT
+7 WRITE !," NECK NODAL MASS.................: ",ONC(165.5,IEN,410)
DO P
if EX=U
QUIT
+8 WRITE !," PAIN, BONE......................: ",ONC(165.5,IEN,411)
DO P
if EX=U
QUIT
+9 WRITE !," PAIN, NECK......................: ",ONC(165.5,IEN,412)
DO P
if EX=U
QUIT
+10 WRITE !," PATHOLOGIC FRACTURE.............: ",ONC(165.5,IEN,413)
DO P
if EX=U
QUIT
+11 WRITE !," STRIDOR/DIFFICULTY BREATHING....: ",ONC(165.5,IEN,414)
DO P
if EX=U
QUIT
+12 WRITE !," THYROID MASS....................: ",ONC(165.5,IEN,415)
DO P
if EX=U
QUIT
+13 WRITE !," WEIGHT LOSS.....................: ",ONC(165.5,IEN,416)
DO P
if EX=U
QUIT
+14 WRITE !," OTHER...........................: ",ONC(165.5,IEN,417)
+15 IF IOST?1"C".E
WRITE !
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
WRITE !?15,TABLE_" (continued)"
GOTO DSW
+16 DO P
if EX=U
QUIT
DSW WRITE !!,"DIAGNOISTIC/SURGICAL WORKUP:",!
DO P
if EX=U
QUIT
+1 WRITE !," BONE SCAN.......................: ",ONC(165.5,IEN,418)
DO P
if EX=U
QUIT
+2 WRITE !," CHEST X-RAY.....................: ",ONC(165.5,IEN,419)
DO P
if EX=U
QUIT
+3 WRITE !," CT SCAN OF NECK.................: ",ONC(165.5,IEN,420)
DO P
if EX=U
QUIT
+4 WRITE !," CT SCAN OF CHEST................: ",ONC(165.5,IEN,421)
DO P
if EX=U
QUIT
+5 WRITE !," INCISIONAL BIOPSY...............: ",ONC(165.5,IEN,422)
DO P
if EX=U
QUIT
+6 WRITE !," LARYNGOSCOPY....................: ",ONC(165.5,IEN,423)
DO P
if EX=U
QUIT
+7 WRITE !," NECK X-RAY (AP & LATERAL........: ",ONC(165.5,IEN,424)
DO P
if EX=U
QUIT
+8 WRITE !," NEEDLE ASPIRATION OF NECK NODE..: ",ONC(165.5,IEN,425)
DO P
if EX=U
QUIT
+9 WRITE !," NEEDLE ASPIRATION OF THYROID....: ",ONC(165.5,IEN,426)
DO P
if EX=U
QUIT
+10 WRITE !," MRI OF NECK.....................: ",ONC(165.5,IEN,427)
DO P
if EX=U
QUIT
+11 WRITE !," THYROID SCAN....................: ",ONC(165.5,IEN,428)
DO P
if EX=U
QUIT
+12 WRITE !," ULTRASOUND OF THYROID...........: ",ONC(165.5,IEN,429)
DO P
if EX=U
QUIT
+13 WRITE !," OTHER...........................: ",ONC(165.5,IEN,430)
+14 IF IOST?1"C".E
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
WRITE !?15,TABLE_" (continued)"
GOTO DOID
+15 DO P
if EX=U
QUIT
DOID WRITE !!,"DATE OF INITIAL DIAGNOSIS.........: ",ONC(165.5,IEN,3)
DO P
if EX=U
QUIT
+1 WRITE !,"PRIMARY SITE (ICD-O-2)............: ",TOPCOD," ",ONC(165.5,IEN,20)
+2 WRITE !,"HISTOLOGY/BEHAVIOR CODE (ICD-O-2).: ",ONC(165.5,IEN,22)
DO P
if EX=U
QUIT
+3 WRITE !,"GRADE.............................: ",ONC(165.5,IEN,24)
DO P
if EX=U
QUIT
+4 WRITE !,"BLOOD VESSEL INVASION.............: ",ONC(165.5,IEN,431)
DO P
if EX=U
QUIT
+5 WRITE !,"EXTRA-THYROIDAL EXTENSION.........: ",ONC(165.5,IEN,432)
DO P
if EX=U
QUIT
+6 WRITE !,"DIAGNOSTIC CONFIRMATION...........: ",ONC(165.5,IEN,26)
+7 IF IOST?1"C".E
WRITE !
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
GOTO III
+8 DO P
if EX=U
QUIT
III SET TABLE="TABLE III - EXTENT OF DISEASE AND AJCC STAGE"
+1 IF IOST'?1"C".E
WRITE !
IF ($Y'<(LIN-4))
DO HDR
+2 WRITE !?15,TABLE,!
DO P
if EX=U
QUIT
+3 WRITE !,"SIZE OF TUMOR (mm)................: ",ONC(165.5,IEN,29)
DO P
if EX=U
QUIT
+4 WRITE !,"MULTIFOCAL........................: ",ONC(165.5,IEN,433)
DO P
if EX=U
QUIT
+5 WRITE !,"REGIONAL NODES EXAMINED...........: ",ONC(165.5,IEN,33)
DO P
if EX=U
QUIT
+6 WRITE !,"REGIONAL NODES POSITIVE...........: ",ONC(165.5,IEN,32)
DO P
if EX=U
QUIT
+7 WRITE !,"LOCATION OF POSITIVE NODES........: ",ONC(165.5,IEN,434)
DO P
if EX=U
QUIT
+8 WRITE !!,"SITE(S) OF DISTANT METASTASIS:",!
DO P
if EX=U
QUIT
+9 WRITE !," SITE OF DISTANT METASTASIS #1...: ",ONC(165.5,IEN,34)
DO P
if EX=U
QUIT
+10 WRITE !," SITE OF DISTANT METASTASIS #2...: ",ONC(165.5,IEN,34.1)
DO P
if EX=U
QUIT
+11 WRITE !," SITE OF DISTANT METASTASIS #3...: ",ONC(165.5,IEN,34.2)
+12 IF IOST?1"C".E
WRITE !
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
WRITE !?15,TABLE_" (continued)"
GOTO AJCCCS
+13 DO P
if EX=U
QUIT
AJCCCS WRITE !!,"AJCC CLINICAL STAGE (cTNM):",!
DO P
if EX=U
QUIT
+1 WRITE !," T-CODE........................: ",ONC(165.5,IEN,37.1)
DO P
if EX=U
QUIT
+2 WRITE !," N-CODE........................: ",ONC(165.5,IEN,37.2)
DO P
if EX=U
QUIT
+3 WRITE !," M-CODE........................: ",ONC(165.5,IEN,37.3)
DO P
if EX=U
QUIT
+4 WRITE !," AJCC STAGE....................: ",ONC(165.5,IEN,38)
DO P
if EX=U
QUIT
AJCCPS WRITE !!,"AJCC PATHOLOGIC STAGE (pTNM):",!
DO P
if EX=U
QUIT
+1 WRITE !," T-CODE........................: ",ONC(165.5,IEN,85)
DO P
if EX=U
QUIT
+2 WRITE !," N-CODE........................: ",ONC(165.5,IEN,86)
DO P
if EX=U
QUIT
+3 WRITE !," M-CODE........................: ",ONC(165.5,IEN,87)
DO P
if EX=U
QUIT
+4 WRITE !," AJCC STAGE....................: ",ONC(165.5,IEN,88)
+5 IF IOST?1"C".E
WRITE !
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
WRITE !?15,TABLE_" (continued)"
GOTO SB
+6 DO P
if EX=U
QUIT
SB WRITE !!,"STAGED BY:",!
DO P
if EX=U
QUIT
+1 WRITE !," CLINICAL STAGE................: ",ONC(165.5,IEN,19)
DO P
if EX=U
QUIT
+2 WRITE !," PATHOLOGIC STAGE..............: ",ONC(165.5,IEN,89)
+3 IF IOST?1"C".E
WRITE !
KILL DIR
SET DIR(0)="E"
DO ^DIR
if 'Y
QUIT
DO HDR
GOTO IV
+4 DO P
if EX=U
QUIT
IV DO ^ONCTPC8A
KILL ;Kill Variables and Exit
+1 KILL CDS,CDSOT,CS,CSDAT,CSIEN,CSPNT,DLC,DOB,DOIT,FIL,LIN,LOS,NCDS
+2 KILL NCDSIEN,NCDSOT,ONC,ONDATE,PG,SURG,SURG1,SURG2,SURGDT,TABLE
+3 KILL %,DIR,DIROUT,DIRUT,DTOUT,DUOUT,X,Y
+4 QUIT
P ;Print
+1 IF ($Y'<(LIN-1))
Begin DoDot:1
+2 IF IOST?1"C".E
KILL DIR
SET DIR(0)="E"
DO ^DIR
IF 'Y
SET EX=U
QUIT
+3 DO HDR
QUIT
End DoDot:1
if EX=U
QUIT
WRITE !?15,TABLE_" (continued)",!
+4 QUIT
TASK ;Queue a task
+1 KILL IO("Q"),ZTUCI,ZTDTH,ZTIO,ZTSAVE
+2 SET ZTRTN="PRT^ONCTPC8"
SET ZTREQ="@"
SET ZTSAVE("ZTREQ")=""
+3 SET ZTDESC="Print Thyroid PCE"
+4 FOR V2=1:1
SET V1=$PIECE(ONCOLST,"^",V2)
if V1=""
QUIT
SET ZTSAVE(V1)=""
+5 DO ^%ZTLOAD
DO ^%ZISC
USE IO
WRITE !,"Request Queued",!
+6 KILL V1,V2,ONCOLST,ZTSK
QUIT
HDR ;Header
+1 WRITE @IOF
SET PG=PG+1
NEW BLANKS
SET $PIECE(BLANKS," ",SITTAB-$LENGTH(PATNAM)-4)=" "
+2 WRITE " ",PATNAM,BLANKS,SITEGP,!,?1,SSN,?TOPTAB-3,TOPNAM," ",TOPCOD
+3 WRITE $SELECT($LENGTH(PG)=2:" ",1:" "),PG,!,DASHES
+4 WRITE !?20," PCE Study of Thyroid Cancer"
+5 WRITE ?59,ONDATE,!,DASHES
+6 QUIT