At 12:53 PM 4/7/2005, Larry Lustig wrote:

I'm trying to use the MapiMail plugins to help send automatic
emails when a record is entered into a table.

I have gotten the program code to work using MAPIMAIL3.RBL.
I format my request, call the RBL, get the R:Base mail screen,
click send (without making and changes), answer Yes when asked
if I want to allow another program to use Outlook to send mail,
and the mail is sent.


To automate the e-mails, using the MAPIMAIL3.RBL or MAPIMAIL4.RBL
PLUGIN, you'll need to use the option of 'SendDirect:TRUE'.

Here's an example:

-- Start

-- SendMAPIMail3.RMD to demonstrate the use of custom plugin
-- Includes the option to send directly
-- Supported in a command file as well as in EEP.
-- Author: A. Razzak Memon
-- Created: August 20, 2003
-- Updated: December 18, 2004
-- MAPI = Messaging Application Programming Interface
-- Note:
-- You MUST place MAPIMail3.RBL PLUGIN in C:\RBTI\RBG7 directory.
-- Each parameter MUST start with pipe '|' symbol.
-- Use Comma ',' to add more entries for To:, Cc: and Bcc:
-- Use Semicolon ';' to add more entries for Attachments:

CLS
PAUSE 2 USING 'Now Let''s Automate Everything!' +
CAPTION ' Send MAPIMail3' ICON APPS

CLEAR VAR vParameters, vQuote, vPipe, vTo, vSubject, vCc, vBcc, vBody, +
vAttachments, vSendDirect

SET VAR vParameters TEXT = NULL
SET VAR vQuote TEXT = (CVAL('QUOTES'))
SET VAR vDummy TEXT = 'vDummy'
SET VAR vPipe TEXT = '|'
SET VAR vTo TEXT = 'To:[EMAIL PROTECTED]'
SET VAR vSubject TEXT = 'Subject:Sending MAPI Mail'
SET VAR vCc TEXT = 'Cc:[EMAIL PROTECTED]'
SET VAR vBcc TEXT = 'Bcc:[EMAIL PROTECTED]'
SET VAR vBody TEXT = 'Body:Now you can also use this cool feature of R:BASE 7.x for Windows'
SET VAR vAttachments TEXT = +
'Attachments:D:\RB70Data\ConComp\RBASE.DAT;D:\RB70Data\ConComp\GlobalVARS.RMD'
SET VAR vSendDirect TEXT = 'SendDirect:TRUE'
SET VAR vParameters = +
(.vQuote+.vDummy&.vPipe+.vTo&.vPipe+.vSubject&.vPipe+.vCc&.vPipe+.vBcc&.vPipe+.vBody +
&+.vPipe+.vAttachments&.vPipe+.vSendDirect)


CLS
PLUGIN MAPIMail3.RBL &vParameters

PAUSE 2 USING 'Enjoy the Endless Possibilities of R:BASE 7.x for Windows!' +
CAPTION ' Using Custom Plugins' ICON APPS

CLEAR VAR vParameters, vQuote, vPipe, vTo, vSubject, vCc, vBcc, vBody, +
vAttachments, vSendDirect
RETURN

-- End

Hope that helps!

Very Best R:egards,

Razzak.



Reply via email to