source: WorldVistAEHR/trunk/r/SCHEDULING-SD-SC/SCUTBK2.m@ 1710

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

initial load of WorldVistAEHR

File size: 1.4 KB
Line 
1SCUTBK2 ;ALB/MJK - Scheduling Broker Utilities ;[ 03/07/95 10:02 AM ]
2 ;;5.3;Scheduling;**41**;AUG 13, 1993
3 ;
4 Q
5 ;
6FINDC(SCDATA,SC) ; -- broker callback to actually use FIND^DIC
7 N SCFILE,SCIENS,SCFIELDS,SCFLAGS,SCFROM,SCPART,SCVAL,SCMAX,SCXREF,SCREEN,SCID,SCROOT,SCDILIST
8 D CHK^SCUTBK
9 ;
10 ; -- parse array to parameters
11 D PARSE^SCUTBK(.SC)
12 D TMP^SCUTBK
13 ;
14 D FIND^DIC(SCFILE,SCIENS,SCFIELDS,SCFLAGS,SCVAL,SCMAX,SCXREF,SCREEN,SCID,"SCDATA")
15 ;
16 Q
17 ;
18GETSC(SCDATA,SC) ; -- broker callback to actually use GETS^DIQ
19 ;
20 N SCFILE,SCIENS,SCFIELDS,SCFLAGS,SCFROM,SCPART,SCVAL,SCMAX,SCXREF,SCREEN,SCID,SCROOT,SCERR
21 D CHK^SCUTBK
22 ;
23 ; -- parse array to parameters
24 D PARSE^SCUTBK(.SC)
25 D TMP^SCUTBK
26 ;
27 D GETS^DIQ(SCFILE,SCIENS,SCFIELDS,SCFLAGS,"SCDATA","SCERR")
28 ;
29 N Y,SCFLD,N,X,J,C
30 S N=0
31 D SET("[Data]")
32 S SCFLD=0 F S SCFLD=$O(SCDATA(SCFILE,SCIENS,SCFLD)) Q:'SCFLD D
33 . S X=SCFILE_"^"_$E(SCIENS,1,$L(SCIENS)-1)_"^"_SCFLD_"^"
34 . ; -- below call to $$GET1 is too slow...working w/FM team for speed
35 . ;IF $$GET1^DID(SCFILE,SCFLD,"","TYPE")="WORD-PROCESSING" D
36 . IF $P($G(^DD(SCFILE,SCFLD,0)),U,4)[";0" D
37 . . D SET(X_"[WORD PROCESSING]")
38 . . S J=0 F S J=$O(SCDATA(SCFILE,SCIENS,SCFLD,J)) Q:'J D
39 . . . D SET(SCDATA(SCFILE,SCIENS,SCFLD,J))
40 . . D SET("$$END$$")
41 . E D
42 . . D SET(X_$G(SCDATA(SCFILE,SCIENS,SCFLD,"I"))_"^"_$G(SCDATA(SCFILE,SCIENS,SCFLD,"E")))
43 ;
44 IF $D(SCERR) D
45 . D SET("[ERROR]")
46 ;
47 K SCDATA M SCDATA=Y
48 Q
49 ;
50SET(X) ;
51 S N=N+1
52 S Y(N)=X
53 Q
54 ;
Note: See TracBrowser for help on using the repository browser.