source: FOIAVistA/trunk/r/PROSTHETICS-RMPR-RMPO-RMPS/RMPOLETU.m@ 1094

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

initial load of FOIAVistA 6/30/08 version

File size: 991 bytes
Line 
1RMPOLETU ;EDS/PAK - HO LETTERS - Update Post Letter Transaction file ;7/24/98
2 ;;3.0;PROSTHETICS;**29**;Feb 09, 1996
3 ;
4FILE(DFN,LET,LN,L) ;Update file 665.4 with Patient Letter
5 ;
6 ;This is a function that sets up an entry in file 665.4.
7 ;If it succeeds, it returns ONE.
8 ;If it fails, it returns an error_number;error_type.
9 ;
10 ; I/P : DFN= Pointer to the Patient file (# 2)
11 ; L = Prosthetics Letter IEN
12 ; LET= Name of word processing style text array to use in MOVE command
13 ; LN = Number of lines printed in LET
14 ;
15 ;Create Entry
16 N DA,DD,DIC,DIK,DINUM,DLAYGO,DO,IEN,X
17 S DIC="^RMPR(665.4,",DIC(0)="L",X=DFN,DLAYGO=665.4
18 D FILE^DICN
19 ;
20 I +Y<1 Q "1;Could not create an entry for Patient #"_DFN_"."
21 ;
22 ;Put fields on zero node
23 ;
24 S IEN=+Y,X=DFN_U_L_U_DT_U_DUZ_"^^"_RMPO("STA")
25 S ^RMPR(665.4,IEN,0)=X
26 ;
27 ;Move in Word Processing Text
28 ;
29 M ^RMPR(665.4,IEN,1)=@LET
30 S ^RMPR(665.4,IEN,1,0)="^^"_LN_U_LN_DT
31 ;
32 ;Reindex entry
33 ;
34 S DIK=DIC,DA=IEN D IX1^DIK
35 ;
36 Q 1
Note: See TracBrowser for help on using the repository browser.