Hello All,
I am using the %MIS.OA.MSG.auto program to send emails for different things. The email is always from the user that triggers the email. Is there a way to have the email always come from the sameaddress? For example instead of coming from SARDARO,AL, from Admission History.
Thank You,
Al Sardaro RN
Nursing Clinical Information Systems Coordinator
Columbia Memorial Hospital
71 Prospect Ave
Hudson, NY 12534
![]()
Hello Al,
Not with %MIS.OA.MSG.auto. There isn’t a way to specify the sender with that macro. To specify the sender you would have to use %Z.mail. I’ve never tried it myself, let me know if you get it to work for you! Below is the macro documentation for %Z.mail.
;;
;; takes text in a file and sends it to the outbox for delivery to recipients
;; listed in an RAF structure.
;;
;; Arguments:
;; A = ^text file (presumed in the format stored by Z.text.ed)
;; B = text file type "SAF"|"RAF"|"RAF+CRLF"
;; C = ^recip structure - If no recipients provided this procedure will prompt for them.
;; D = subject
;; E = Return outbox urn in /MIS.XO.MSG.urn if E is valued
;; F = from. If not present, use MIS.PARAM.mail.recipient (Used for SMTP ONLY)
;; G = Mail server over ride. Used if @ MEDITECH for Alert.
;;
;; Returns ERR.MSG (TRUE) if couldn't send mail to the Outbox.
;;
Mike McEldowney
Director of Information Services
Salina Regional Health Center
400 S Santa Fe
Salina, KS 67401
785-452-6005
Z.mail is a client server utility and it does let you specify the sender.
MIS.OA.MSG.auto and the MIS.SMTP programs (Magic) build the sender email address out of some user and MIS information.
I will be showing examples of using Z.mail (Client Server) and MIS.SMTP programs (Magic) at my NPR/RD Tips and Tricks session at MUSE next Thursday.
If you are a magic site, and therefore need to let the MIS.OA.MSG.auto program or MIS.SMTP programs use the @.user value to decide on the sender, there is a way to pretend to be some other user so that the email can come from some dummy user you build in the user dictionary.
I will be out of the office at the MUSE International Conference.
May 28th thru June 1st.
Joe Cocuzzo
Vice President
Report Writing Services
Iatric Systems, Inc.
Phone/Fax: (978) 805-4115
Email: Joe.C...@iatric.com
Web: www.iatric.com
Iatric Systems is a leading provider of integrated software applications, interfaces and reporting solutions for hospitals and healthcare systems.

You have to be very careful, but you can change the @.user temporarily but you HAVE to be VERY CAREFUL and make sure you set it back before you exit your macro…
;Save the current user
@.user^SAVE.USER,
".USR"^NAME,
; Assign PAYROLL user as the sender
"PAYROLL"^/[NAME],
;Now send the message
@SEND.MAIL.MACRO,
; Now restore back to current user
SAVE.USER^/[NAME]
Thanks,
Brian
From: meditech-...@mtusers.com [mailto:meditech-...@mtusers.com]
On Behalf Of Michael McEldowney
Sent: Friday, May 25, 2012 12:12 PM
To: 'Sardaro, Al'; Medit...@mtusers.com
Subject: Re: [MT-L] Emailing
Hello Al,