source: FOIAVistA/trunk/r/ZZREGIONAL-A1C-A5C-CRHD-RGED-RGUT-RGWB-RG/RGUTIN8.m@ 1397

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

initial load of FOIAVistA 6/30/08 version

File size: 1.2 KB
Line 
1RGUTIN8 ;CAIRO/DKM - Inits for MSM;04-Sep-1998 11:26;DKM
2 ;;2.1;RUN TIME LIBRARY;;Mar 22, 1999
3OPEN(X1,X2) ;
4 N Z
5 S X2=$G(X2,"R")
6 F Z=51:1:55 I '$D(^TMP("HFS",$J,Z)) D Q
7 .ZT:Z=55 "TMOF"
8 .O Z:(X1:$S("RrWw"[X2:X2,1:"R")::::$S("Bb"[X2:"",1:$C(13,10)))
9 .U Z
10 .ZT:$ZA "OPEN"
11 .S ^TMP("HFS",$J,Z)=X1,X1=Z
12 Q
13CLOSE(X) N Z
14 S Z=X,X=$G(^TMP("HFS",$J,X))
15 K ^(Z)
16 C Z
17 Q
18CLOSEALL N Z
19 F Z=0:0 S Z=$O(^TMP("HFS",$J,Z)) Q:'Z C Z
20 K ^TMP("HFS",$J)
21 Q
22EOF ZT:$ZC "EOF"
23 Q
24EOFERR() Q $ZE["ZEOF"
25READ(X,Y) ;
26 U:$G(Y)'="" Y
27 R X
28 Q $ZC&'$L(X)
29DELETE(X) ;
30 S X=$ZOS(2,X)
31 Q
32RENAME(X1,X2) ;
33 N Z
34 S Z=$ZOS(3,X1,X2)
35 Q
36DIR(X1,X2,X3) ;
37 N Z
38 S X1=$ZOS(12,X1,0),X2=+$G(X2),X3=$G(X3,"^UTILITY(""DIR"",$J)")
39 K @X3
40 F Z=1:1 Q:(X2&(Z>X2))!($P(X1,"^")="") S @X3@($P(X1,"^"))="",X1=$ZOS(13,X1)
41 Q
42DEFDIR(X) ;
43 S X=$G(X,$P($G(^XTV(8989.3,1,"DEV")),U))
44 S:$E(X,$L(X))'="\" X=X_"\"
45 Q X
46DIRDLM() Q "\\\"
47FREE(X) S X=$ZOS(9,$E(X))
48 Q X*$P(X,"^",2)*$P(X,"^",3)/1048576
49ERR(X1,X2,X3) ;
50 S X1=$E($P($ZE,">"),2,99),X2=$P($P($ZE,">",2),":"),X3=X1
51 S:X2["*" X2=""
52 S:$E(X1)="Z" X3=$E(X1,2,99),X1="ZTRAP"
53 Q
54FTP(X1,X2,X3,X4,X5,X6,X7) ;
55 Q
56RAISE(X) ZT $G(X)
57TRAP(X) Q $S($D(X):"$ZT="""_X_"""",1:"$ZT")
58SIZE(X) N I,Y,Z
59 S Z=$ZOS(12,X,0),Z=$P(Z,"^",2,999),Y=0
60 I Z'="" F I=30:-1:27 S Y=Y*256+$A(Z,I)
61 Q Y
Note: See TracBrowser for help on using the repository browser.