Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Email from Visual Foxpro
Message
From
27/09/1999 09:26:16
 
 
To
27/09/1999 07:37:29
General information
Forum:
Visual FoxPro
Category:
Internet applications
Miscellaneous
Thread ID:
00269228
Message ID:
00269268
Views:
24
>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
Map
View

Click here to load this message in the networking platform