source: WorldVistAEHR/trunk/r/MENTAL_HEALTH-YS-RUCL-YI-YT/YSTUSE.m@ 619

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

initial load of WorldVistAEHR

File size: 1.0 KB
Line 
1YSTUSE ;ASF/ALB- PSYCHOLOGICAL TEST USEAGE REPORTING ; 9/1/04 11:02am
2 ;;5.01;MENTAL HEALTH;**87**;Dec 30, 1994
3 ;called as a server option from YS TEST USAGE
41 N YSB,YSY,DFN,YSTST,YSCOMP,N,N1,A
5 K ^TMP($J,"YSTAT")
6 S ^TMP($J,"YSTAT",1)=$$SITE^VASITE
7 S XMA=1 X XMREC
8 I XMRG="" S ^TMP($J,"YSTAT",12)="Dates can not be resolved" D SENDER Q ;-->out
9 S YSB=$P(XMRG,U),YSY=$P(XMRG,U,2)
10 S ^TMP($J,"YSTAT",2)="From: "_YSB_" To: "_YSY
11 S ^TMP($J,"YSTAT",3)=" "
12TT ;test ck
13 S N=20,DFN=0
14 F S DFN=$O(^YTD(601.2,DFN)) Q:DFN'>0 D TST
15 S YSTST=0 F S YSTST=$O(A(YSTST)) Q:YSTST'>0 D
16 . S N=N+1
17 . S ^TMP($J,"YSTAT",N)=$P($G(^YTT(601,YSTST,0)),U)_U_YSTST_U_A(YSTST)
18SENDER S XMSUB="MH testing Statistics: "_XQSUB,XMY(XMFROM)="",XMTEXT="^TMP($J,""YSTAT"","
19 S XMDUZ="MH automated testing REPLY"
20 N XMFROM,XMZ,XMREC,XMCHAN D ^XMD
21 Q
22TST ;test check
23 S YSTST=0 F S YSTST=$O(^YTD(601.2,DFN,1,YSTST)) Q:YSTST'>0 D COMP
24 Q
25COMP ;date range
26 S YSCOMP=YSB-.01 F S YSCOMP=$O(^YTD(601.2,DFN,1,YSTST,1,YSCOMP)) Q:YSCOMP'>0!(YSCOMP>YSY) S A(YSTST)=$G(A(YSTST))+1
Note: See TracBrowser for help on using the repository browser.