Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MAPI help

Status
Not open for further replies.

dex888

Programmer
Aug 13, 2005
7
MY
I have a code in my program

mailsession lms_MAPISession
mailmessage lmm_Message

lms_MAPISession = CREATE mailsession
IF lms_MAPISession.MailLogon() = MailReturnSuccess! THEN
// Mail Sesion is ok so Populate the Message
lmm_Message.Subject = "testing"
lmm_Message.NoteText = "test send attachement file"
lmm_Message.Recipient[ 1 ].RecipientType = mailTo!
lmm_Message.Recipient[ 1 ].Name = 'soo'
lmm_Message.Recipient[ 1 ].Address = 'soo@gmail.com'

IF lms_MAPISession.MailSend( lmm_Message ) = MailReturnSuccess! THEN
Messagebox( 'Mail', 'Message was sent.' )
Else
Messagebox( 'Mail', 'Message was unable to sent.' )
END IF

lms_MAPISession.MailLogoff()
END IF

DESTROY lms_MAPISession


Although I received message of "Message was sent", but when I check my Outlook, it was unsuccessfully send. May I know what happen?

Another problem is I can't add sender name in my mail, how can I do that?

Thank you very much
 
Your code is fine
Can you send any email from Outlook?
The email address is ok?
Where do you want to add the sender name?
zkar
 
After a few test, it works OK now with the code above which I also don't know where went wrong, thanks for the reply.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top