source: WorldVistAEHR/trunk/r/ORDER_ENTRY_RESULTS_REPORTING-OR-OCX--ORRC--ORRJ/OCXBDT7.m@ 700

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

initial load of WorldVistAEHR

File size: 3.5 KB
RevLine 
[613]1OCXBDT7 ;SLC/RJS,CLA - BUILD OCX PACKAGE DIAGNOSTIC ROUTINES (Build Runtime Library Routine OCXDI3) ;8/04/98 13:21
2 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**32**;Dec 17,1997
3 ;; ;;ORDER CHECK EXPERT version 1.01 released OCT 29,1998
4 ;
5EN() ;
6 ;
7 N R,LINE,TEXT,NOW,RUCI,XCM
8 S NOW=$$NOW^OCXBDT3,RUCI=$$CUCI^OCXBDT
9 F LINE=1:1:999 S TEXT=$P($T(TEXT+LINE),";",2,999) Q:TEXT S TEXT=$P(TEXT,";",2,999) S R(LINE,0)=$$CONV^OCXBDT3(TEXT)
10 ;
11 M ^TMP("OCXBDT",$J,"RTN")=R
12 ;
13 S DIE="^TMP(""OCXBDT"","_$J_",""RTN"",",XCN=0,X="OCXDI3"
14 W !,X X ^%ZOSF("SAVE") W " ... ",XCM," Lines filed" K ^TMP("OCXBDT",$J,"RTN")
15 ;
16 Q XCM
17 ;
18TEXT ;
19 ;;OCXDI3 ;SLC/RJS,CLA - OCX PACKAGE DIAGNOSTIC UTILITY ROUTINE ;|NOW|
20 ;;|OCXLIN2|
21 ;;|OCXLIN3|
22 ;; ;
23 ;;S ;
24 ;; ; Multiple Utilities
25 ;; Q
26 ;; ;
27 ;;ADDMULT(OCXCREF,OCXDD,OCXFLD) ;
28 ;; ;
29 ;; ;
30 ;; N QUIT,OCXDA,OCXGREF,OCXNAME,DDPATH,INDEX
31 ;; ;
32 ;; S DDPATH=$P($P($$APPEND($$APPEND(OCXCREF,OCXDD),OCXFLD),"(",2),")",1)
33 ;; F INDEX=1:1:$L(DDPATH,",") S OCXDA($L(DDPATH,",")-INDEX)=+$P($P(DDPATH,",",INDEX),":",2)
34 ;; S OCXDA=$G(OCXDA(0)) K OCXDA(0)
35 ;; Q:'OCXFLGC 0 I (OCXFLGA) S QUIT=$$READ("Y"," Do you want to add a local '"_$$FILENAME^OCXBDTD(+OCXFLD)_"' multiple ?","YES") Q:'QUIT (QUIT[U)
36 ;; ;
37 ;; S OCXGREF=$$GETREF^OCXDI2(+OCXFLD,.OCXDA,1)
38 ;; D CREATE($$APPEND(OCXCREF,OCXDD),OCXFLD,.OCXDA,1)
39 ;; ;
40 ;; Q 0
41 ;; ;
42 ;;DELMULT(OCXCREF,OCXDD) ;
43 ;; ;
44 ;; N QUIT,OCXGREF,DA,INDEX,DDPATH
45 ;; ;
46 ;; Q:'OCXFLGC 0 I (OCXFLGA) S QUIT=$$READ("Y"," Do you want to delete the local '"_$$FILENAME^OCXBDTD(+OCXDD)_"' multiple ?","YES") Q:'QUIT (QUIT[U)
47 ;; ;
48 ;; S DDPATH=$P($P($$APPEND(OCXCREF,OCXDD),"(",2),")",1)
49 ;; F INDEX=1:1:$L(DDPATH,",") S DA($L(DDPATH,",")-INDEX)=+$P($P(DDPATH,",",INDEX),":",2)
50 ;; S DA=$G(DA(0)) K DA(0)
51 ;; S OCXGREF=$$GETREF^OCXDI2(+OCXDD,.DA,1)
52 ;; ;
53 ;; D DIE^OCXDI2(+OCXDD,OCXGREF,.01,"@",.DA,$L(DDPATH,",")-1)
54 ;; K @OCXCREF@(OCXDD) W:OCXFLGR !!," deleted..."
55 ;; ;
56 ;; Q 0
57 ;; ;
58 ;;CREATE(OCXCREF,OCXDD,OCXDA,OCXLVL) ;
59 ;; ;
60 ;; N OCXFLD,OCXGREF
61 ;; ;
62 ;; S OCXGREF=$$GETREF^OCXDI2(+OCXDD,.OCXDA,OCXLVL) Q:'$L(OCXGREF) S:'OCXDA OCXDA=$O(@(OCXGREF_"""@"")"),-1)+1
63 ;; ;
64 ;; I '$D(@(OCXGREF_"0)")) S @(OCXGREF_"0)")=U_$$FILEHDR^OCXBDTD(+OCXDD)_U_U
65 ;; ;
66 ;; S OCXFLD=0 F S OCXFLD=$O(@OCXCREF@(OCXDD,OCXFLD)) Q:'OCXFLD Q:(OCXFLD[":") I '$$EXFLD^OCXDI1(+OCXDD,OCXFLD) D
67 ;; .I $L($G(@OCXCREF@(OCXDD,OCXFLD,"E"))) D DIE^OCXDI2(OCXDD,OCXGREF,OCXFLD,@OCXCREF@(OCXDD,OCXFLD,"E"),.OCXDA,OCXLVL)
68 ;; ;
69 ;; D PUSH(.OCXDA)
70 ;; S OCXFLD="" F S OCXFLD=$O(@OCXCREF@(OCXDD,OCXFLD)) Q:'$L(OCXFLD) I (OCXFLD[":") D
71 ;; .S OCXDA=$P(OCXFLD,":",2) W ! D CREATE($$APPEND(OCXCREF,OCXDD),OCXFLD,.OCXDA,OCXLVL+1)
72 ;; D POP(.OCXDA)
73 ;; Q
74 ;; ;
75 ;;PUSH(OCXDA) ;
76 ;; N OCXSUB S OCXSUB="" F S OCXSUB=$O(OCXDA(OCXSUB),-1) Q:'OCXSUB S OCXDA(OCXSUB+1)=OCXDA(OCXSUB)
77 ;; S OCXDA(1)=OCXDA,OCXDA=0
78 ;; Q
79 ;; ;
80 ;;POP(OCXDA) ;
81 ;; N OCXSUB S OCXSUB="" F S OCXSUB=$O(OCXDA(OCXSUB)) Q:'OCXSUB S OCXDA(OCXSUB)=$G(OCXDA(OCXSUB+1))
82 ;; S OCXDA=OCXDA(1) K OCXDA($O(OCXDA(""),-1))
83 ;; Q
84 ;; ;
85 ;;APPEND(ARRAY,OCXSUB) ;
86 ;; S:'(OCXSUB=+OCXSUB) OCXSUB=""""_OCXSUB_""""
87 ;; Q:'(ARRAY["(") ARRAY_"("_OCXSUB_")"
88 ;; Q $E(ARRAY,1,$L(ARRAY)-1)_","_OCXSUB_")"
89 ;; ;
90 ;;READ(OCXZ0,OCXZA,OCXZB,OCXZL) ;
91 ;; N OCXLINE,DIR,DTOUT,DUOUT,DIRUT,DIROUT
92 ;; Q:'$L($G(OCXZ0)) U
93 ;; S DIR(0)=OCXZ0
94 ;; S:$L($G(OCXZA)) DIR("A")=OCXZA
95 ;; S:$L($G(OCXZB)) DIR("B")=OCXZB
96 ;; F OCXLINE=1:1:($G(OCXZL)-1) W !
97 ;; D ^DIR
98 ;; I $D(DTOUT)!$D(DUOUT)!$D(DIRUT)!$D(DIROUT) Q U
99 ;; Q Y
100 ;; ;
101 ;;PAUSE() Q:'OCXFLGC 0 W " Press Enter " R X:DTIME W ! Q (X[U)
102 ;; ;
103 ;;$
104 ;1;
105 ;
Note: See TracBrowser for help on using the repository browser.