DINIT294 ;SFISC/MKO-FORM AND BLOCK FILES ;18JAN2016
;;22.2;VA FileMan;;Jan 05, 2016;Build 42
;;Per VA Directive 6402, this routine should not be modified.
;;Submitted to OSEHRA 5 January 2015 by the VISTA Expertise Network.
;;Based on Medsphere Systems Corporation's MSC FileMan 1051.
;;Licensed under the terms of the Apache License, Version 2.0.
;
F I=1:2 S X=$T(Q+I) Q:X="" S Y=$E($T(Q+I+1),4,999),X=$E(X,4,999) S:$A(Y)=126 I=I+1,Y=$E(Y,2,999)_$E($T(Q+I+1),5,99) S:$A(Y)=61 Y=$E(Y,2,999) S @X=Y
G ^DINIT295
Q Q
;;^DD(.4032,3,21,5,0)
;;=of those two kinds of fields so that the user can press <RET> to view or
;;^DD(.4032,3,21,6,0)
;;=edit the subfields in the multiple or invoke an editor to view the
;;^DD(.4032,3,21,7,0)
;;=contents of the word processing field.
;;^DD(.4032,3,"DT")
;;=2940413
;;^DD(.4032,4,0)
;;=POINTER LINK^FX^^1;1^K:$L(X)>245!($L(X)<1) X I $D(X) D PLINK^DDSIT
;;^DD(.4032,4,3)
;;=Answer must be 1-245 characters in length.
;;^DD(.4032,4,21,0)
;;=^^9^9^2940907^^
;;^DD(.4032,4,21,1,0)
;;=If the fields displayed in this block are reached through a relational
;;^DD(.4032,4,21,2,0)
;;=jump from the primary file of the form, enter the relational expression
;;^DD(.4032,4,21,3,0)
;;=that describes this jump. Your frame of reference is the primary file of
;;^DD(.4032,4,21,4,0)
;;=the form.
;;^DD(.4032,4,21,5,0)
;;=
;;^DD(.4032,4,21,6,0)
;;=For example, if the primary file has a field #999 called TEST that points
;;^DD(.4032,4,21,7,0)
;;=to the file associated with this block, enter
;;^DD(.4032,4,21,8,0)
;;=
;;^DD(.4032,4,21,9,0)
;;= 999 or TEST
;;^DD(.4032,4,"DT")
;;=2931201
;;^DD(.4032,5,0)
;;=REPLICATION^NJ3,0^^2;1^K:+X'=X!(X>999)!(X<2)!(X?.E1"."1N.N) X
;;^DD(.4032,5,3)
;;=Type a Number between 2 and 999, 0 Decimal Digits
;;^DD(.4032,5,21,0)
;;=^^3^3^2940907^^
;;^DD(.4032,5,21,1,0)
;;=If this is a repeating block, enter the number of times the fields
;;^DD(.4032,5,21,2,0)
;;=defined in this block should be replicated. If used, this number must
;;^DD(.4032,5,21,3,0)
;;=be greater than 1.
;;^DD(.4032,5,"DT")
;;=2940503
;;^DD(.4032,6,0)
;;=INDEX^F^^2;2^K:$L(X)>63!($L(X)<1) X
;;^DD(.4032,6,3)
;;=Answer must be 1-63 characters in length.
;;^DD(.4032,6,21,0)
;;=^^7^7^2941020^
;;^DD(.4032,6,21,1,0)
;;=Enter the name of the cross reference that should be used to pick up the
;;^DD(.4032,6,21,2,0)
;;=subentries in the multiple. ScreenMan will initially display the
;;^DD(.4032,6,21,3,0)
;;=subentries to the user sorted in the order defined by this index. The
;;^DD(.4032,6,21,4,0)
;;=default INDEX is B.
;;^DD(.4032,6,21,5,0)
;;=
;;^DD(.4032,6,21,6,0)
;;=If the multiple has no index, or you wish to display the subentries
;;^DD(.4032,6,21,7,0)
;;=in record number order, enter !IEN.
;;^DD(.4032,6,21,8,0)
;;= LEAVE THIS VALUE EMPTY IF YOU WANT TO ENTER 'COMPUTED MULTIPLE' CODE TO DO THE SELECTION
;;^DD(.4032,7,0)
;;=INITIAL POSITION^S^f:FIRST;l:LAST;n:NEW;u:USER'S LAST^2;3^Q
;;^DD(.4032,7,3)
;;=Enter the initial position within the repeating block; f(FIRST), l(LAST), n(NEW), or u(USER'S LAST).
;;^DD(.4032,7,21,0)
;;=^^5^5^2940908^
;;^DD(.4032,7,21,1,0)
;;=This is the position in the list where the cursor should initially rest
;;^DD(.4032,7,21,2,0)
;;=when the user first navigates to the repeating block. NEW indicates that
;;^DD(.4032,7,21,3,0)
;;=the cursor should initially rest on the blank line at the end of the list.
;;^DD(.4032,7,21,4,0)
;;=USER'S LAST is the last choice that the User has made for this file -- what
;;^DD(.4032,7,21,5,0)
;;=would be retrieved by the SPACE-BAR. The default INITIAL POSITION is FIRST.
;;^DD(.4032,7,"DT")
;;=2940503
;;^DD(.4032,8,0)
;;=DISALLOW LAYGO^S^0:NO;1:YES;^2;4^Q
;;^DD(.4032,8,21,0)
;;=^^3^3^2940907^^
;;^DD(.4032,8,21,1,0)
;;=If set to YES, this prohibits the user from entering new subentries into
;;^DD(.4032,8,21,2,0)
;;=the multiple. If null or set to NO, the setting in the data dictionary
;;^DD(.4032,8,21,3,0)
;;=determines whether LAYGO is allowed.
;;^DD(.4032,8,"DT")
;;=2940505
;;^DD(.4032,9,0)
;;=FIELD FOR SELECTION^F^^2;5^K:$L(X)>30!($L(X)<1) X
;;^DD(.4032,9,3)
;;=Answer must be 1-30 characters in length.
;;^DD(.4032,9,21,0)
;;=^^5^5^2940907^^
;;^DD(.4032,9,21,1,0)
;;=This is the field order of the field that defines the column position of
;;^DD(.4032,9,21,2,0)
;;=the blank line at the end of the list. The default is the first editable
;;^DD(.4032,9,21,3,0)
;;=field in the block. This is also the field before which ScreenMan prints
;;^DD(.4032,9,21,4,0)
;;=the plus sign (+) to indicate there are more entries above or below the
;;^DD(.4032,9,21,5,0)
;;=displayed list.
;;^DD(.4032,9,"DT")
;;=2940506
;;^DD(.4032,10,0)
;;=ASK 'OK'^S^0:NO;1:YES;^2;6^Q
;;^DD(.4032,10,21,0)
;;=^^5^5^2990420^
;;^DD(.4032,10,21,1,0)
;;=Answer 'YES' to ask the user whether the looked-up entry is 'OK'. If only
;;^DD(.4032,10,21,2,0)
;;=one match is made to the user's lookup value, then ScreenMan will ask
;;^DD(.4032,10,21,3,0)
;;="OK?" instead of automatically selecting the found entry. This property
;;^DD(.4032,10,21,4,0)
;;=corresponds to the "V" flag in the DIC(0) input variable to ^DIC and only
;;^DD(.4032,10,21,5,0)
;;=pertains to multiple-valued fields.
;;^DD(.4032,10,"DT")
;;=2990420
;;^DD(.4032,11,0)
;;=PRE ACTION^K^^11;E1,245^K:$L(X)>245 X D:$D(X) ^DIM
;;^DD(.4032,11,3)
;;=This is Standard MUMPS code.
;;^DD(.4032,11,9)
;;=@
;;^DD(.4032,11,21,0)
;;=^^5^5^2940907^
;;^DD(.4032,11,21,1,0)
;;=Enter MUMPS code that is executed whenever the user reaches this block.
;;^DD(.4032,11,21,2,0)
;;=
;;^DD(.4032,11,21,3,0)
;;=This pre-action is a characteristic of the block only as it is used on
;;^DD(.4032,11,21,4,0)
;;=this form. If you place this block on another form, you can define a
;;^DD(.4032,11,21,5,0)
;;=different pre-action.
;;^DD(.4032,11,"DT")
;;=2930610
;;^DD(.4032,12,0)
;;=POST ACTION^K^^12;E1,245^K:$L(X)>245 X D:$D(X) ^DIM
;;^DD(.4032,12,3)
;;=This is Standard MUMPS code.
;;^DD(.4032,12,9)
;;=@
;;^DD(.4032,12,21,0)
;;=^^5^5^2940907^
;;^DD(.4032,12,21,1,0)
;;=Enter MUMPS code that is executed whenever the user leaves this block.
;;^DD(.4032,12,21,2,0)
;;=
;;^DD(.4032,12,21,3,0)
;;=This post-action is a characteristic of the block only as it is used on
;;^DD(.4032,12,21,4,0)
;;=this form. If you place this block on another form, you can define a
;;^DD(.4032,12,21,5,0)
;;=different post-action.
;;^DD(.4032,12,"DT")
;;=2930610
;;^DD(.4032,98,0)
;;=COMPUTED MULTIPLE^K^^COMP MUL;E1,999^D ^DIM
;;^DD(.4032,98,3)
;;=Enter valid MUMPS code
;;^DD(.4032,98,21,0)
;;=^^4^4^3160118^
;;^DD(.4032,98,21,1,0)
;;=This MUMPS code will display a list of the values of the .01 field
;;^DD(.4032,98,21,2,0)
;;=of the File being edited. The code must Xecute the DICMX variable
;;^DD(.4032,98,21,3,0)
;;=with D0 set to the IEN of the entry to be displayed.
;;^DD(.4032,98,21,4,0)
;;=The code is automatically generated for a record selection page.
;;^DD(.4032,98.1,0)
;;=COMPUTED MUL PTR^NJ13,9^^COMP MUL PTR;E1,999^K:+$P(X,"E")'=X X
;;^DD(.4032,98.1,3)
;;=Enter a number with up to 13 digits and 9 decimal places
;;^DD(.4032,98.1,21,0)
;;=^^2^2^3160118^
;;^DD(.4032,98.1,21,1,0)
;;=The field contains the File# of the file from which the Computed Multiple values
;;^DD(.4032,98.1,21,2,0)
;;=are retrieved (usually the file being edited by the Form).
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HDINIT294 7713 printed Dec 13, 2024@02:51:18 Page 2
DINIT294 ;SFISC/MKO-FORM AND BLOCK FILES ;18JAN2016
+1 ;;22.2;VA FileMan;;Jan 05, 2016;Build 42
+2 ;;Per VA Directive 6402, this routine should not be modified.
+3 ;;Submitted to OSEHRA 5 January 2015 by the VISTA Expertise Network.
+4 ;;Based on Medsphere Systems Corporation's MSC FileMan 1051.
+5 ;;Licensed under the terms of the Apache License, Version 2.0.
+6 ;
+7 FOR I=1:2
SET X=$TEXT(Q+I)
if X=""
QUIT
SET Y=$EXTRACT($TEXT(Q+I+1),4,999)
SET X=$EXTRACT(X,4,999)
if $ASCII(Y)=126
SET I=I+1
SET Y=$EXTRACT(Y,2,999)_$EXTRACT($TEXT(Q+I+1),5,99)
if $ASCII(Y)=61
SET Y=$EXTRACT(Y,2,999)
SET @X=Y
+8 GOTO ^DINIT295
Q QUIT
+1 ;;^DD(.4032,3,21,5,0)
+2 ;;=of those two kinds of fields so that the user can press <RET> to view or
+3 ;;^DD(.4032,3,21,6,0)
+4 ;;=edit the subfields in the multiple or invoke an editor to view the
+5 ;;^DD(.4032,3,21,7,0)
+6 ;;=contents of the word processing field.
+7 ;;^DD(.4032,3,"DT")
+8 ;;=2940413
+9 ;;^DD(.4032,4,0)
+10 ;;=POINTER LINK^FX^^1;1^K:$L(X)>245!($L(X)<1) X I $D(X) D PLINK^DDSIT
+11 ;;^DD(.4032,4,3)
+12 ;;=Answer must be 1-245 characters in length.
+13 ;;^DD(.4032,4,21,0)
+14 ;;=^^9^9^2940907^^
+15 ;;^DD(.4032,4,21,1,0)
+16 ;;=If the fields displayed in this block are reached through a relational
+17 ;;^DD(.4032,4,21,2,0)
+18 ;;=jump from the primary file of the form, enter the relational expression
+19 ;;^DD(.4032,4,21,3,0)
+20 ;;=that describes this jump. Your frame of reference is the primary file of
+21 ;;^DD(.4032,4,21,4,0)
+22 ;;=the form.
+23 ;;^DD(.4032,4,21,5,0)
+24 ;;=
+25 ;;^DD(.4032,4,21,6,0)
+26 ;;=For example, if the primary file has a field #999 called TEST that points
+27 ;;^DD(.4032,4,21,7,0)
+28 ;;=to the file associated with this block, enter
+29 ;;^DD(.4032,4,21,8,0)
+30 ;;=
+31 ;;^DD(.4032,4,21,9,0)
+32 ;;= 999 or TEST
+33 ;;^DD(.4032,4,"DT")
+34 ;;=2931201
+35 ;;^DD(.4032,5,0)
+36 ;;=REPLICATION^NJ3,0^^2;1^K:+X'=X!(X>999)!(X<2)!(X?.E1"."1N.N) X
+37 ;;^DD(.4032,5,3)
+38 ;;=Type a Number between 2 and 999, 0 Decimal Digits
+39 ;;^DD(.4032,5,21,0)
+40 ;;=^^3^3^2940907^^
+41 ;;^DD(.4032,5,21,1,0)
+42 ;;=If this is a repeating block, enter the number of times the fields
+43 ;;^DD(.4032,5,21,2,0)
+44 ;;=defined in this block should be replicated. If used, this number must
+45 ;;^DD(.4032,5,21,3,0)
+46 ;;=be greater than 1.
+47 ;;^DD(.4032,5,"DT")
+48 ;;=2940503
+49 ;;^DD(.4032,6,0)
+50 ;;=INDEX^F^^2;2^K:$L(X)>63!($L(X)<1) X
+51 ;;^DD(.4032,6,3)
+52 ;;=Answer must be 1-63 characters in length.
+53 ;;^DD(.4032,6,21,0)
+54 ;;=^^7^7^2941020^
+55 ;;^DD(.4032,6,21,1,0)
+56 ;;=Enter the name of the cross reference that should be used to pick up the
+57 ;;^DD(.4032,6,21,2,0)
+58 ;;=subentries in the multiple. ScreenMan will initially display the
+59 ;;^DD(.4032,6,21,3,0)
+60 ;;=subentries to the user sorted in the order defined by this index. The
+61 ;;^DD(.4032,6,21,4,0)
+62 ;;=default INDEX is B.
+63 ;;^DD(.4032,6,21,5,0)
+64 ;;=
+65 ;;^DD(.4032,6,21,6,0)
+66 ;;=If the multiple has no index, or you wish to display the subentries
+67 ;;^DD(.4032,6,21,7,0)
+68 ;;=in record number order, enter !IEN.
+69 ;;^DD(.4032,6,21,8,0)
+70 ;;= LEAVE THIS VALUE EMPTY IF YOU WANT TO ENTER 'COMPUTED MULTIPLE' CODE TO DO THE SELECTION
+71 ;;^DD(.4032,7,0)
+72 ;;=INITIAL POSITION^S^f:FIRST;l:LAST;n:NEW;u:USER'S LAST^2;3^Q
+73 ;;^DD(.4032,7,3)
+74 ;;=Enter the initial position within the repeating block; f(FIRST), l(LAST), n(NEW), or u(USER'S LAST).
+75 ;;^DD(.4032,7,21,0)
+76 ;;=^^5^5^2940908^
+77 ;;^DD(.4032,7,21,1,0)
+78 ;;=This is the position in the list where the cursor should initially rest
+79 ;;^DD(.4032,7,21,2,0)
+80 ;;=when the user first navigates to the repeating block. NEW indicates that
+81 ;;^DD(.4032,7,21,3,0)
+82 ;;=the cursor should initially rest on the blank line at the end of the list.
+83 ;;^DD(.4032,7,21,4,0)
+84 ;;=USER'S LAST is the last choice that the User has made for this file -- what
+85 ;;^DD(.4032,7,21,5,0)
+86 ;;=would be retrieved by the SPACE-BAR. The default INITIAL POSITION is FIRST.
+87 ;;^DD(.4032,7,"DT")
+88 ;;=2940503
+89 ;;^DD(.4032,8,0)
+90 ;;=DISALLOW LAYGO^S^0:NO;1:YES;^2;4^Q
+91 ;;^DD(.4032,8,21,0)
+92 ;;=^^3^3^2940907^^
+93 ;;^DD(.4032,8,21,1,0)
+94 ;;=If set to YES, this prohibits the user from entering new subentries into
+95 ;;^DD(.4032,8,21,2,0)
+96 ;;=the multiple. If null or set to NO, the setting in the data dictionary
+97 ;;^DD(.4032,8,21,3,0)
+98 ;;=determines whether LAYGO is allowed.
+99 ;;^DD(.4032,8,"DT")
+100 ;;=2940505
+101 ;;^DD(.4032,9,0)
+102 ;;=FIELD FOR SELECTION^F^^2;5^K:$L(X)>30!($L(X)<1) X
+103 ;;^DD(.4032,9,3)
+104 ;;=Answer must be 1-30 characters in length.
+105 ;;^DD(.4032,9,21,0)
+106 ;;=^^5^5^2940907^^
+107 ;;^DD(.4032,9,21,1,0)
+108 ;;=This is the field order of the field that defines the column position of
+109 ;;^DD(.4032,9,21,2,0)
+110 ;;=the blank line at the end of the list. The default is the first editable
+111 ;;^DD(.4032,9,21,3,0)
+112 ;;=field in the block. This is also the field before which ScreenMan prints
+113 ;;^DD(.4032,9,21,4,0)
+114 ;;=the plus sign (+) to indicate there are more entries above or below the
+115 ;;^DD(.4032,9,21,5,0)
+116 ;;=displayed list.
+117 ;;^DD(.4032,9,"DT")
+118 ;;=2940506
+119 ;;^DD(.4032,10,0)
+120 ;;=ASK 'OK'^S^0:NO;1:YES;^2;6^Q
+121 ;;^DD(.4032,10,21,0)
+122 ;;=^^5^5^2990420^
+123 ;;^DD(.4032,10,21,1,0)
+124 ;;=Answer 'YES' to ask the user whether the looked-up entry is 'OK'. If only
+125 ;;^DD(.4032,10,21,2,0)
+126 ;;=one match is made to the user's lookup value, then ScreenMan will ask
+127 ;;^DD(.4032,10,21,3,0)
+128 ;;="OK?" instead of automatically selecting the found entry. This property
+129 ;;^DD(.4032,10,21,4,0)
+130 ;;=corresponds to the "V" flag in the DIC(0) input variable to ^DIC and only
+131 ;;^DD(.4032,10,21,5,0)
+132 ;;=pertains to multiple-valued fields.
+133 ;;^DD(.4032,10,"DT")
+134 ;;=2990420
+135 ;;^DD(.4032,11,0)
+136 ;;=PRE ACTION^K^^11;E1,245^K:$L(X)>245 X D:$D(X) ^DIM
+137 ;;^DD(.4032,11,3)
+138 ;;=This is Standard MUMPS code.
+139 ;;^DD(.4032,11,9)
+140 ;;=@
+141 ;;^DD(.4032,11,21,0)
+142 ;;=^^5^5^2940907^
+143 ;;^DD(.4032,11,21,1,0)
+144 ;;=Enter MUMPS code that is executed whenever the user reaches this block.
+145 ;;^DD(.4032,11,21,2,0)
+146 ;;=
+147 ;;^DD(.4032,11,21,3,0)
+148 ;;=This pre-action is a characteristic of the block only as it is used on
+149 ;;^DD(.4032,11,21,4,0)
+150 ;;=this form. If you place this block on another form, you can define a
+151 ;;^DD(.4032,11,21,5,0)
+152 ;;=different pre-action.
+153 ;;^DD(.4032,11,"DT")
+154 ;;=2930610
+155 ;;^DD(.4032,12,0)
+156 ;;=POST ACTION^K^^12;E1,245^K:$L(X)>245 X D:$D(X) ^DIM
+157 ;;^DD(.4032,12,3)
+158 ;;=This is Standard MUMPS code.
+159 ;;^DD(.4032,12,9)
+160 ;;=@
+161 ;;^DD(.4032,12,21,0)
+162 ;;=^^5^5^2940907^
+163 ;;^DD(.4032,12,21,1,0)
+164 ;;=Enter MUMPS code that is executed whenever the user leaves this block.
+165 ;;^DD(.4032,12,21,2,0)
+166 ;;=
+167 ;;^DD(.4032,12,21,3,0)
+168 ;;=This post-action is a characteristic of the block only as it is used on
+169 ;;^DD(.4032,12,21,4,0)
+170 ;;=this form. If you place this block on another form, you can define a
+171 ;;^DD(.4032,12,21,5,0)
+172 ;;=different post-action.
+173 ;;^DD(.4032,12,"DT")
+174 ;;=2930610
+175 ;;^DD(.4032,98,0)
+176 ;;=COMPUTED MULTIPLE^K^^COMP MUL;E1,999^D ^DIM
+177 ;;^DD(.4032,98,3)
+178 ;;=Enter valid MUMPS code
+179 ;;^DD(.4032,98,21,0)
+180 ;;=^^4^4^3160118^
+181 ;;^DD(.4032,98,21,1,0)
+182 ;;=This MUMPS code will display a list of the values of the .01 field
+183 ;;^DD(.4032,98,21,2,0)
+184 ;;=of the File being edited. The code must Xecute the DICMX variable
+185 ;;^DD(.4032,98,21,3,0)
+186 ;;=with D0 set to the IEN of the entry to be displayed.
+187 ;;^DD(.4032,98,21,4,0)
+188 ;;=The code is automatically generated for a record selection page.
+189 ;;^DD(.4032,98.1,0)
+190 ;;=COMPUTED MUL PTR^NJ13,9^^COMP MUL PTR;E1,999^K:+$P(X,"E")'=X X
+191 ;;^DD(.4032,98.1,3)
+192 ;;=Enter a number with up to 13 digits and 9 decimal places
+193 ;;^DD(.4032,98.1,21,0)
+194 ;;=^^2^2^3160118^
+195 ;;^DD(.4032,98.1,21,1,0)
+196 ;;=The field contains the File# of the file from which the Computed Multiple values
+197 ;;^DD(.4032,98.1,21,2,0)
+198 ;;=are retrieved (usually the file being edited by the Form).