AZHLSC28 ; IHS/ADC/GTH:KEU:JN - SAC CHAPTER 2: M LANGUAGE PROGRAMMING STANDARDS & CONVENTIONS ; [ 08/06/1998 2:16 PM ]
;;5.0;AZHLSC;;JUL 10, 1996
;CHANGED DIF="Z(" TO GLOBAL AND OTHER REFERENCES TO THE
;ARRAY TO THE GLOBAL REFERENCE TO ACCOMMODATE LARGE RTNS SIZES
;IHS/ABQ/KEU 4/7/95
;W !!!,$P($P($T(+1),";",2),"-",2)
NEW A,A3,A4,A5,ARG,B,CH,COM,DIF,G,I,J,LIN,NORTNS,NUL,R,Q,XCNP,Z
D END
S Q="""",A4="="" O ",A5="="" C ",NORTNS=$O(^UTILITY($J,""))=""
S AZHL=1
F S AZHL=$O(^UTILITY($J,AZHL)) Q:AZHL="" W:AZHLTERM "." K Z S (AZHL0,X)=AZHL,DIF="^TMP($J,""Z"",",XCNP=0 X "X ^%ZOSF(""LOAD""),AZHLGFCX" I S XCNP=XCNP-1 D
.F Z=3:1:XCNP S Z(Z)=^TMP($J,"Z",Z,0) K ^TMP($J,"Z",Z,0) D
..;I Z(Z)[A4!(Z(Z)[A5) D EN^AZHLSC47 Q:AZHLSC4I=1 D EN^AZHLSC46 Q:AZHLSC4I=1 S ^TMP($J,"281",AZHL,Z)=Z(Z)
..Q
.Q
101 D TTL^AZHLSC("2.8.1, (6.3.1) Kernel Utilities")
I NORTNS D NRTN^AZHLSC Q
I $L($O(^TMP($J,"281",""))) W !?10,"Possible use of 'OPEN' or 'CLOSE' in an executed string." S %="" F S %=$O(^TMP($J,"281",%)) Q:%="" S A=0 F S A=$O(^TMP($J,"281",%,A)) Q:'A W !?10,"+",A,"^",%," : ",^(A)
Q
END K ^TMP($J,"281"),^("Z"),Z
Q
AZHLSC28 ; IHS/ADC/GTH:KEU:JN - SAC CHAPTER 2: M LANGUAGE PROGRAMMING STANDARDS & CONVENTIONS ; [ 08/06/1998 2:16 PM ]
+1 ;;5.0;AZHLSC;;JUL 10, 1996
+2 ;CHANGED DIF="Z(" TO GLOBAL AND OTHER REFERENCES TO THE
+3 ;ARRAY TO THE GLOBAL REFERENCE TO ACCOMMODATE LARGE RTNS SIZES
+4 ;IHS/ABQ/KEU 4/7/95
+5 ;W !!!,$P($P($T(+1),";",2),"-",2)
+6 NEW A,A3,A4,A5,ARG,B,CH,COM,DIF,G,I,J,LIN,NORTNS,NUL,R,Q,XCNP,Z
+7 DO END
+8 SET Q=""""
SET A4="="" O "
SET A5="="" C "
SET NORTNS=$ORDER(^UTILITY($JOB,""))=""
+9 SET AZHL=1
+10 FOR
SET AZHL=$ORDER(^UTILITY($JOB,AZHL))
IF AZHL=""
QUIT
IF AZHLTERM
WRITE "."
KILL Z
SET (AZHL0,X)=AZHL
SET DIF="^TMP($J,""Z"","
SET XCNP=0
XECUTE "X ^%ZOSF(""LOAD""),AZHLGFCX"
IF $TEST
SET XCNP=XCNP-1
Begin DoDot:1
+11 FOR Z=3:1:XCNP
SET Z(Z)=^TMP($JOB,"Z",Z,0)
KILL ^TMP($JOB,"Z",Z,0)
Begin DoDot:2
+12 ;I Z(Z)[A4!(Z(Z)[A5) D EN^AZHLSC47 Q:AZHLSC4I=1 D EN^AZHLSC46 Q:AZHLSC4I=1 S ^TMP($J,"281",AZHL,Z)=Z(Z)
+13 QUIT
End DoDot:2
+14 QUIT
End DoDot:1
101 DO TTL^AZHLSC("2.8.1, (6.3.1) Kernel Utilities")
+1 IF NORTNS
DO NRTN^AZHLSC
QUIT
+2 IF $LENGTH($ORDER(^TMP($JOB,"281","")))
WRITE !?10,"Possible use of 'OPEN' or 'CLOSE' in an executed string."
SET %=""
FOR
SET %=$ORDER(^TMP($JOB,"281",%))
IF %=""
QUIT
SET A=0
FOR
SET A=$ORDER(^TMP($JOB,"281",%,A))
IF 'A
QUIT
WRITE !?10,"+",A,"^",%," : ",^(A)
+3 QUIT
END KILL ^TMP($JOB,"281"),^("Z"),Z
+1 QUIT