source: WorldVistAEHR/trunk/r/ORDER_ENTRY_RESULTS_REPORTING-OR-OCX--ORRC--ORRJ/ORRU.m@ 1270

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

initial load of WorldVistAEHR

File size: 1.2 KB
Line 
1ORRU ; SLC/JER - Scroll-mode Utility Subroutines ; 5-APR-2002 12:39:51
2 ;;3.0;ORDER ENTRY/RESULTS REPORTING;**174**;Dec 17, 1997
3STOP(PROMPT,SCROLL) ; Call DIR at bottom of screen
4 N DIR,X,Y
5 I $E(IOST)'="C" S Y="" G STOPX
6 I +$G(SCROLL),(IOSL>($Y+5)) F W ! Q:IOSL<($Y+6)
7 S DIR(0)="FO^1:1"
8 S DIR("A")=$S($G(PROMPT)]"":PROMPT,1:"Press RETURN to continue or '^' to exit")
9 S DIR("?")="Enter '^' to quit present action or '^^' to quit to menu"
10 D ^DIR I $D(DIRUT),(Y="") K DIRUT
11 S Y=$S(Y="^":0,Y="^^":0,$D(DTOUT):"",Y="":1,1:1_U_Y)
12STOPX Q Y
13READ(TYPE,PROMPT,DEFAULT,HELP,SCREEN) ; Calls reader, returns response
14 N DIR,X,Y
15 S DIR(0)=TYPE
16 I $D(SCREEN) S DIR("S")=SCREEN
17 I $G(PROMPT)]"" S DIR("A")=PROMPT
18 I $G(DEFAULT)]"" S DIR("B")=DEFAULT
19 I $D(HELP) S DIR("?")=HELP
20 D ^DIR
21 I $G(X)="@" S Y="@" G READX
22 I Y]"",($L($G(Y),U)'=2) S Y=Y_U_$G(Y(0),Y)
23READX Q Y
24LISTREAD(ORLIST,ANSTYPE) ; Present list to user for selection of item(s)
25 N ORI,ORL,ORY S (ORI,ORY)=0
26 S ANSTYPE=$S($G(ANSTYPE)]"":$G(ANSTYPE),1:"N")
27 F S ORI=$O(ORLIST(ORI)) Q:+ORI'>0 D
28 . W !,ORI,?5,$P(ORLIST(ORI),U,2) S ORL=ORI
29 I +$G(ORL) D
30 . W !
31 . S ORY=$$READ(ANSTYPE_"A^1:"_ORL,"Select "_$P(ORLIST,U)_": ")
32 . I +ORY S ORY=$G(ORLIST(+ORY))
33 Q ORY
Note: See TracBrowser for help on using the repository browser.