changing email properties

  • Thread starter Thread starter Taliesin
  • Start date Start date
T

Taliesin

I'm using this function to send an email from excel, is their any way to
change the From details so that I can use the department e-mail rather than
my personal one?

Function SendIt(FromEmail, ToEmail, ToCC, ToBCC, ToSubject, ToBody,
ToAttachment)
Set out = CreateObject("Outlook.Application")
Set mapi = out.GetNameSpace("MAPI")
Set email = out.CreateItem(0)
email.Recipients.Add (ToEmail)
email.Subject = ToSubject
email.Body = ToBody
email.Send
Set outlook = Nothing
Set mapi = Nothing
End Function
 
Is there no way to "spoof" the sender details so that any replies come back
through a set path?
 
Taliesin ,

If I am understanding you correctly, isn't that exactly what logon to
another profile does? Not spoofing, but does used that account.
 
Main problem is that if I put a password in a macro I breach computer
security rules and get sacked,

Spoofing the address allows me to send the e-mail from my own address
(already logged in) but make it look as if it has come from the department
and redirect all replies that way so that it can be dealt with by anyone on
the shift.
 
Taliesin,

It would seem to me that you have a legitimate reason there to have a shared
account that anyone on the shift could deal with, and I would suggest that
you put that to your management and seek dispensation. If they say no, then
they maybe don't deserve to have an efficient organisation.

Personally, I would make the case, and if the firm disagrees, go with it. I
definitely would not try to spoof anything in order to circumvent company
policy.
 
Back
Top