General information
Category:
Internet applications
>Please help me out how can i email from vfp
>
>
>Thanks
Hi Javaid
Check the help for MAPI control and use this code that works for me.
OleMAPIsession is MAPI session droped on a form.
OLEMAPImsg is MAPI message droped on a form.
Good luck
Mo
**********************************************************************
* Procedure : SendEmail
* Purpose : Initialize the E-MAIL message and send it
*
* Calls :
*
* Parameters : Name Type Purpose
* pReceiverEmail C Receiver E-Mail address
* pEmailMessage C Message to be send.
* pEmailSubject C Message Subject.
*
* Comments : Must have 32bit OS and MAPI.ocx
*
**********************************************************************
LPARAMETER pReceiverEmail, pEmailMessage, pEmailSubject
*--Sign on if you have not done it yet.
IF _screen.activeform.OleMAPIsession.SessionID = 0
_screen.activeform.OleMAPIsession.SignOn
ENDIF
*--Initialize the E-MAIL message and send it
With _SCREEN.Activeform.OLEMAPImsg
.MsgIndex = -1
.RecipDisplayName = pReceiverEmail
.MsgSubject = pEmailSubject
.MsgNoteText = pEmailMessage
.SessionID = _SCREEN.Activeform.OleMAPISession.SessionID
.Send(.F.)
Endwith
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only