source: FOIAVistA/trunk/r/ORDER_ENTRY_RESULTS_REPORTING-OR-OCX--ORRC--ORRJ/OCXBDT8.m@ 1683

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

initial load of FOIAVistA 6/30/08 version

File size: 3.6 KB
Line 
1OCXBDT8 ;SLC/RJS,CLA - BUILD OCX PACKAGE DIAGNOSTIC ROUTINES (Build Runtime Library Routine OCXDI4) ;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="OCXDI4"
14 W !,X X ^%ZOSF("SAVE") W " ... ",XCM," Lines filed" K ^TMP("OCXBDT",$J,"RTN")
15 ;
16 Q XCM
17 ;
18TEXT ;
19 ;;OCXDI4 ;SLC/RJS,CLA - OCX PACKAGE DIAGNOSTIC UTILITY ROUTINE ;|NOW|
20 ;;|OCXLIN2|
21 ;;|OCXLIN3|
22 ;; ;
23 ;;S ;
24 ;; ; Field Utilities
25 ;; Q
26 ;; ;
27 ;;EDITFLD(OCXCREF,OCXDD,OCXFLD,OCXSUB) ;
28 ;; ;
29 ;; N DDPATH,OCXDA,OCXPC,OCXLVL,QUIT
30 ;; ;
31 ;; S QUIT=0,DDPATH=$P($P($$APPEND(OCXCREF,OCXDD),"(",2),")",1)
32 ;; S OCXLVL=$L(DDPATH,",")
33 ;; F OCXPC=1:1:OCXLVL S OCXDA(OCXLVL-OCXPC)=+$P($P(DDPATH,",",OCXPC),":",2)
34 ;; S OCXDA=OCXDA(0) K OCXDA(0)
35 ;; I $L($G(@OCXCREF@(OCXDD,OCXFLD,"E"))) D
36 ;; .N RESP
37 ;; .Q:'OCXFLGC I (OCXFLGA) S RESP=$$READ("Y"," Do you want to change the local '"_$$FILENAME^OCXBDTD(+OCXDD)_"' field ?","YES") I 'RESP S QUIT=(RESP[U) Q
38 ;; .S OCXGREF=$$GETREF^OCXDI2(+OCXDD,.OCXDA,OCXLVL-1) Q:'$L(OCXGREF)
39 ;; .D DIE^OCXDI2(OCXDD,OCXGREF,OCXFLD,@OCXCREF@(OCXDD,OCXFLD,"E"),.OCXDA,OCXLVL-1)
40 ;; ;
41 ;; Q QUIT
42 ;; ;
43 ;;DELFLD(OCXCREF,OCXDD,OCXFLD,OCXSUB) ;
44 ;; ;
45 ;; N DDPATH,OCXDA,OCXPC,OCXLVL,QUIT,RESP
46 ;; ;
47 ;; S QUIT=0,DDPATH=$P($P($$APPEND(OCXCREF,OCXDD),"(",2),")",1)
48 ;; S OCXLVL=$L(DDPATH,",")
49 ;; F OCXPC=1:1:OCXLVL S OCXDA(OCXLVL-OCXPC)=+$P($P(DDPATH,",",OCXPC),":",2)
50 ;; S OCXDA=OCXDA(0) K OCXDA(0)
51 ;; Q:'OCXFLGC 0 I (OCXFLGA) S RESP=$$READ("Y"," Do you want to Delete the local '"_$$FILENAME^OCXBDTD(+OCXDD)_"' value ?","YES") I 'RESP S QUIT=(RESP[U) Q QUIT
52 ;; S OCXGREF=$$GETREF^OCXDI2(+OCXDD,.OCXDA,OCXLVL-1) Q:'$L(OCXGREF)
53 ;; D DIE^OCXDI2(OCXDD,OCXGREF,OCXFLD,"@",.OCXDA,OCXLVL-1)
54 ;; ;
55 ;; Q QUIT
56 ;; ;
57 ;;CREATE(OCXCREF,OCXDD,OCXDA,OCXLVL) ;
58 ;; ;
59 ;; N OCXFLD,OCXGREF
60 ;; ;
61 ;; S OCXGREF=$$GETREF^OCXDI2(+OCXDD,.OCXDA,OCXLVL) Q:'$L(OCXGREF) S:'OCXDA OCXDA=$O(@(OCXGREF_"""@"")"),-1)+1
62 ;; ;
63 ;; I '$D(@(OCXGREF_"0)")) S @(OCXGREF_"0)")=U_$$FILEHDR^OCXBDTD(+OCXDD)_U_U
64 ;; ;
65 ;; S OCXFLD=0 F S OCXFLD=$O(@OCXCREF@(OCXDD,OCXFLD)) Q:'OCXFLD Q:(OCXFLD[":") I '$$EXFLD^OCXDI1(+OCXDD,OCXFLD) D
66 ;; .I $L($G(@OCXCREF@(OCXDD,OCXFLD,"E"))) D DIE^OCXDI2(OCXDD,OCXGREF,OCXFLD,@OCXCREF@(OCXDD,OCXFLD,"E"),.OCXDA,OCXLVL)
67 ;; ;
68 ;; D PUSH(.OCXDA)
69 ;; S OCXFLD="" F S OCXFLD=$O(@OCXCREF@(OCXDD,OCXFLD)) Q:'$L(OCXFLD) I (OCXFLD[":") D
70 ;; .S OCXDA=$P(OCXFLD,":",2) W ! D CREATE($$APPEND(OCXCREF,OCXDD),OCXFLD,.OCXDA,OCXLVL+1)
71 ;; D POP(.OCXDA)
72 ;; Q
73 ;; ;
74 ;;PUSH(OCXDA) ;
75 ;; N OCXSUB S OCXSUB="" F S OCXSUB=$O(OCXDA(OCXSUB),-1) Q:'OCXSUB S OCXDA(OCXSUB+1)=OCXDA(OCXSUB)
76 ;; S OCXDA(1)=OCXDA,OCXDA=0
77 ;; Q
78 ;; ;
79 ;;POP(OCXDA) ;
80 ;; N OCXSUB S OCXSUB="" F S OCXSUB=$O(OCXDA(OCXSUB)) Q:'OCXSUB S OCXDA(OCXSUB)=$G(OCXDA(OCXSUB+1))
81 ;; S OCXDA=OCXDA(1) K OCXDA($O(OCXDA(""),-1))
82 ;; Q
83 ;; ;
84 ;;APPEND(ARRAY,OCXSUB) ;
85 ;; S:'(OCXSUB=+OCXSUB) OCXSUB=""""_OCXSUB_""""
86 ;; Q:'(ARRAY["(") ARRAY_"("_OCXSUB_")"
87 ;; Q $E(ARRAY,1,$L(ARRAY)-1)_","_OCXSUB_")"
88 ;; ;
89 ;;READ(OCXZ0,OCXZA,OCXZB,OCXZL) ;
90 ;; N OCXLINE,DIR,DTOUT,DUOUT,DIRUT,DIROUT
91 ;; Q:'$L($G(OCXZ0)) U
92 ;; S DIR(0)=OCXZ0
93 ;; S:$L($G(OCXZA)) DIR("A")=OCXZA
94 ;; S:$L($G(OCXZB)) DIR("B")=OCXZB
95 ;; F OCXLINE=1:1:($G(OCXZL)-1) W !
96 ;; D ^DIR
97 ;; I $D(DTOUT)!$D(DUOUT)!$D(DIRUT)!$D(DIROUT) Q U
98 ;; Q Y
99 ;; ;
100 ;;PAUSE() Q:'OCXFLGC 0 W " Press Enter " R X:DTIME W ! Q (X[U)
101 ;; ;
102 ;;$
103 ;1;
104 ;
Note: See TracBrowser for help on using the repository browser.