source: WorldVistAEHR/trunk/r/LEXICON_UTILITY-LEX-GMPT/LEXDM.m@ 814

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

initial load of WorldVistAEHR

File size: 3.2 KB
Line 
1LEXDM ; ISL Default Misc - Mod/Del Sel/Create ; 09-23-96
2 ;;2.0;LEXICON UTILITY;;Sep 23, 1996;Build 1
3 ;
4 ; Entry: S X=$$MOD^LEXDM(X)
5 ; Input X 1=Filter, 2=Display, 3=Vocabulary or 4=Context
6 ; Returns "^^" Double up-arrow, 0 no action taken, 1 Modify
7 ; default entry or "@" delete default entry
8 ;
9MOD(LEXX) ; Modify or Delete
10 ;
11 S LEXX=+($G(LEXX)) Q:LEXX<0 0 S LEXX=LEXX\1 Q:LEXX>4 0
12 N DIR,X,Y,DIRUT,DTOUT,DUOUT,DIROUT
13 S:LEXX=1 DIR("A",1)="search filter" S:LEXX=2 DIR("A",1)="display format"
14 S:LEXX=3 DIR("A",1)="vocabulary" S:LEXX=4 DIR("A",1)="shortcut context"
15 S:$L($G(DIR("A",1))) DIR("A",1)="User default "_DIR("A",1)
16 S DIR("A",3)=" 1 Modify",DIR("A",4)=" 2 Delete"
17 S (DIR("A",2),DIR("A",5))=" "
18 S:LEXX=1 DIR(0)="SAO^1:Modify Default Filter;2:Delete Default Filter"
19 S:LEXX=2 DIR(0)="SAO^1:Modify Default Display;2:Delete Default Display"
20 S:LEXX=3 DIR(0)="SAO^1:Modify Default Vocabulary;2:Delete Default Vocabulary"
21 S:LEXX=4 DIR(0)="SAO^1:Modify Default Shortcut Context;2:Delete Default Shortcut Context"
22 S DIR("A")="Select: ",DIR("B")="1"
23 D ^DIR S LEXX=$S(X=1:1,X=2:"@",X="@":"@",1:0) S:Y="^^" LEXX=Y Q LEXX
24 ;
25 ;-----------------------------------------------------------------
26 ; Entry: S X=$$MTH^LEXDM(X)
27 ; Input X 1=Filter, 2=Display
28 ; Returns "^^" Timeout or Double-uparrow, "^" Method not
29 ; selected, 1 Select default from a predefined list
30 ; or 2 Create a user defined default
31 ;
32 ; LEXM Method of building string
33 ; LEXF Flag, indicates the default type
34 ;
35MTH(LEXX) ; Method - Select a predefined or Create new
36 Q:'$L($G(LEXX)) "" Q:+LEXX'>0 "" Q:+LEXX'<3 ""
37 N LEXF,LEXM S LEXF=+LEXX,LEXM=$$METH W:+LEXM=1!(+LEXM=2) !!
38 S LEXX=LEXM S:"12"[LEXM LEXX=LEXM
39 S:'$L($G(LEXM))!(LEXM="^") LEXX="^" S:LEXM="^^" LEXX="^^"
40 Q LEXX
41METH(LEXX) ; Select method
42 N DIR,X,Y,DIRUT,DTOUT,DUOUT,DIROUT
43 I +LEXF=1 D
44 . S DIR("A",1)="Search filters (screens) to limit the response"
45 . S DIR("A",3)=" 1 Select from predefined filters"
46 . S DIR("A",4)=" 2 Create your own filter"
47 . S DIR("??")="^D HF^LEXDM"
48 I +LEXF=2 D
49 . S DIR("A",1)="Display format to used during look-up"
50 . S DIR("A",3)=" 1 Select from predefined display formats"
51 . S DIR("A",4)=" 2 Create your own display format"
52 . S DIR("??")="^D HD^LEXDM"
53 S (DIR("A",2),DIR("A",5))=" "
54 S DIR(0)="SAO^1:Predefined Set;2:Create your own set"
55 S DIR("A")="Select: ",DIR("B")="1"
56 D ^DIR S LEXX=$S(+Y>0:+Y,1:Y) S:$D(DTOUT) LEXX="^^" Q LEXX
57HF ; Help for filters - DIC("S")
58 W !!,"When conducting searches in the Lexicon, you may find that many of the"
59 W !,"expressions found are not reasonable in the context of intended use."
60 W !,"Many of these ""unreasonable"" expressions can be filtered out during the"
61 W !,"search, providing a much smaller and more meaningful list of expressions"
62 W !,"to select from. Several of these filters have been predefined and made "
63 W !,"available. You may select from this list of predefined filters or create"
64 W !,"your own." Q
65HD ; Help for display - LEXSHOW
66 W !!,"When conducting searches in the Lexicon, you may alter the display format"
67 W !,"of the selection list. There are several commonly used displays which"
68 W !,"have been predefined and made available. You may select from this list or"
69 W !,"create your own." Q
Note: See TracBrowser for help on using the repository browser.