source: WorldVistAEHR/trunk/r/MEDICINE-MC/MCAROC31.m@ 949

Last change on this file since 949 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 3.0 KB
RevLine 
[613]1MCAROC31 ; GENERATED FROM 'MCARCATH3' PRINT TEMPLATE (#972) ; 10/04/96 ; (continued)
2 G BEGIN
3N W !
4T 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)
5 S DISTP=DISTP+1,DILCT=DILCT+1 D:'(DISTP#100) CSTP^DIO2
6 Q
7DT I $G(DUZ("LANG"))>1,Y W $$OUT^DIALOGU(Y,"DD") Q
8 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
9 W Y Q
10M D @DIXX
11 Q
12BEGIN ;
13 S:'$D(DN) DN=1 S DISTP=$G(DISTP),DILCT=$G(DILCT)
14 D N:$X>44 Q:'DN W ?44 S DIP(1)=$S($D(^MCAR(691.1,D0,29,D1,0)):^(0),1:"") S X="TO: "_$S('$D(^MCAR(696,+$P(DIP(1),U,2),0)):"",1:$P(^(0),U,1)) K DIP K:DN Y W X
15 Q
16F1R ;
17 D T Q:'DN D N D N:$X>4 Q:'DN W ?4 S DIP(1)=$S($D(^MCAR(691.1,D0,30)):^(30),1:"") S X="CIRCUMFLEX: "_$S('$D(^MCAR(695.9,+$P(DIP(1),U,1),0)):"",1:$P(^(0),U,1)) K DIP K:DN Y W X
18 S I(1)=31,J(1)=691.32 F D1=0:0 Q:$O(^MCAR(691.1,D0,31,D1))'>0 X:$D(DSC(691.32)) DSC(691.32) S D1=$O(^(D1)) Q:D1'>0 D:$X>15 T Q:'DN D G1
19 G G1R
20G1 ;
21 S X=$G(^MCAR(691.1,D0,31,D1,0)) D N:$X>9 Q:'DN W ?9 S Y=$P(X,U,1) S Y=$S(Y="":Y,$D(^MCAR(696,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,30)
22 D N:$X>33 Q:'DN W ?33 S Y=$P(X,U,2) S Y=$S(Y="":Y,$D(^MCAR(696.1,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,17)
23 D N:$X>33 Q:'DN W ?33 S Y=$P(X,U,4) W:Y]"" $J(Y,7,2)
24 W ?42 S Y=$P(X,U,3) S Y=$S(Y="":Y,$D(^MCAR(696.2,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,25)
25 Q
26G1R ;
27 D N:$X>7 Q:'DN W ?7 X DXS(7,9.2) S DIP(3)=X S X=1,DIP(4)=X S X="",X=$S(DIP(2):DIP(3),DIP(4):X) K DIP K:DN Y W X
28 D N:$X>7 Q:'DN W ?7 X DXS(8,9.3) S DIP(5)=X S X=1,DIP(6)=X S X="",X=$S(DIP(3):DIP(5),DIP(6):X) K DIP K:DN Y W X
29 S I(1)=33,J(1)=691.33 F D1=0:0 Q:$O(^MCAR(691.1,D0,33,D1))'>0 X:$D(DSC(691.33)) DSC(691.33) S D1=$O(^(D1)) Q:D1'>0 D:$X>18 T Q:'DN D H1
30 G H1R
31H1 ;
32 D N:$X>8 Q:'DN W ?8 S DIP(1)=$S($D(^MCAR(691.1,D0,33,D1,0)):^(0),1:"") S X="FROM: "_$S('$D(^MCAR(696,+$P(DIP(1),U,1),0)):"",1:$P(^(0),U,1)) K DIP K:DN Y W X
33 D N:$X>44 Q:'DN W ?44 S DIP(1)=$S($D(^MCAR(691.1,D0,33,D1,0)):^(0),1:"") S X="TO: "_$S('$D(^MCAR(696,+$P(DIP(1),U,2),0)):"",1:$P(^(0),U,1)) K DIP K:DN Y W X
34 Q
35H1R ;
36 D T Q:'DN D N D N:$X>4 Q:'DN W ?4 W "BYPASS GRAFTS ?:"
37 S X=$G(^MCAR(691.1,D0,35)) W ?22 S Y=$P(X,U,2) W:Y]"" $S($D(DXS(9,Y)):DXS(9,Y),1:Y)
38 S I(1)=36,J(1)=691.35 F D1=0:0 Q:$O(^MCAR(691.1,D0,36,D1))'>0 X:$D(DSC(691.35)) DSC(691.35) S D1=$O(^(D1)) Q:D1'>0 D:$X>35 T Q:'DN D I1
39 G I1R
40I1 ;
41 D N:$X>7 Q:'DN W ?7 W "DISTAL ANASTOMOSIS:"
42 S X=$G(^MCAR(691.1,D0,36,D1,0)) D N:$X>9 Q:'DN W ?9 S Y=$P(X,U,1) S Y=$S(Y="":Y,$D(^MCAR(696,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,30)
43 D N:$X>33 Q:'DN W ?33 S Y=$P(X,U,2) S Y=$S(Y="":Y,$D(^MCAR(696.1,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,17)
44 D N:$X>33 Q:'DN W ?33 S Y=$P(X,U,4) W:Y]"" $J(Y,7,2)
45 W ?42 S Y=$P(X,U,3) S Y=$S(Y="":Y,$D(^MCAR(696.4,Y,0))#2:$P(^(0),U,1),1:Y) W $E(Y,1,25)
46 Q
47I1R ;
48 K Y
49 Q
50HEAD ;
51 W !,"--------------------------------------------------------------------------------",!!
Note: See TracBrowser for help on using the repository browser.