EmailOpen(eSubject As String, eContent As String, eRecipientEmail As String, eRecipientName As String, eFileboxName As String, eLogText As String, AddLinkedAddressesTo As String)

 

Opens an email client window for composing and sending an Email.

Use this command when you would like to add linked email addresses to the recipients list.

 

This EmailOpen command takes 7 paramters to prefill the window with default data before it is displayed to the user.


Sender email address and name and server data will be saved and re-used, they only need to be entered once

in the settings panel of the email window. If no settings are entered, then the default settings will be used.

Send Mail Server Default settings can be set in Seminar Pro preferences, Admin panel.

  

Parameters:

 

Name

Type

Description

eSubject

String

Subject (title) of the email

eContent

String

Default body text of the email

eRecipientEmail

String

Email address of the recipient

eRecipientName

String

Full name of the recipient

eFileboxName

String

The name of the filebox control (like "imFB_inf_Files ") from where selected files are copied to the email window. These files are sent as attachments with the email.
Right-Click on the filename to remove an attachment.

eLogText

String

Text to be added to the logging section
at the settings panel of the email window

AddLinkedAddressesTo

String

Determines where any linked email addresses are shown.

 

Possible values: TO, CC or BCC

 

TO : main receivers

CC : carbon copy receivers

BCC : hidden carbon copy receivers (DEFAULT)

 

If EmailOpen is called from any type of record on WindowMain, then the program retrieves the email addresses of any address registered (linked) to it.

 

If any addresses are selected, then only the email addresses of selected linked addresses are used.

 

If no selection was made, then all records are used.

 

Available in:

 

WindowMain

WindowLink

YES

YES

 

 Used in:

 

XojoScript Name

GUID

Send Info by Email

DF78F654-7776-40C8-9F25-2DBC1E1FD2F7

 

Hint: You can find references to XojoScripts which make use of this function by sending the following SQL statement to the database:

Select id,GUID, ScriptName,ScriptCode from im_scripts where ScriptCode Like '%EmailOpen%'

 

Example XojoScript:

 

Dim logtext As String = ""

 

// Set Email Text

Dim title As String = Gettext("imTF_inf_Title")  // subject

Dim body As String = GetText("imTA_inf_Description")

 

// Set Email recipient

Dim email As String = ""  // recipient email

Dim name As String = ""   // recipient name

 

// Set Filebox containing attachment files

Dim filebox As String = "imFB_inf_Files" // filebox name with attachments files

 

// Use 7 Parameters to use default mail server settings (from preferences)

// and add linked (optionaly selected only) address emails to TO, CC, or BCC recipients

EmailOpen(title,body,email,name,filebox,logtext,"BCC")  // "TO","CC" or "BCC"