Well, that's no ordinary rabbit!
Our coders wanted to notified whenever Xigris was ordered on a
patient. We accomplished this through the combination of a rule and a
custom defined keyword. The rule gets attached to the medication. All
the rule does is call the custom keyword. The keyword does all the
work. The keyword has to be created first.
:AA[/["aa"]]|1 is the pt name
:AA[/["aa"]]|0 is the pt acct number
:AA[/["aa"]]|12 is the pt location
:AA[/["aa"]]|10 is the pt room
:AA[/["aa"]]|11 is the pt bed
Here is the keyword code as text with some comments.
;
-- This line puts the date and time into the first line of the message
%Z.date.out(/.DAT)_" - "_@.now^/Z.MSG[1],
; -- The next line adds Xigris text and the pt name and acct number to
line 2
"Xigris has been ordered on "_:AA[/["aa"]]|1_" -
"_:AA[/["aa"]]|0^/Z.MSG[2],
; -- The next line adds the pt location, room and bed to the third line
of the message
" "_:AA[/["aa"]]|12_" "_:AA[/["aa"]]|10_" "_:AA[/["aa"]]|11^/Z.MSG[3],
; -- the next line sets up ARG with the message and recipients ISTJT
and CODEAMB
; -- you can send the message to a printer as well
; -- to send the message to printer PRT123 you could use
Q(^/Z.MSG,"!PRT123")^ARG
; -- Note the ! in front of the printer mnemonic PRT123
Q(^/Z.MSG,"ISTJT","CODEAMB")^ARG,
%MIS.OA.MSG.auto("",ARG)X,
1
Don't see what you
need? Visit one of these other sites
or email me your request (tomt at thomast357.com).