4D Internet Commands v16SMTP_QuickSend |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D Internet Commands v16
SMTP_QuickSend
SMTP_QuickSend
The SMTP_QuickSend command gives the users the ability to build and send a mail message with one command. In the event that you require greater control over your message, or the message is of a more sophisticated nature, the group of SMTP commands based on the SMTP_New command should be utilized. Note: This command cannot be used in converted databases operating in "non-Unicode" mode. hostName is the host name or IP address of the SMTP server where the message will be sent for distribution. msgFrom is a text value containing an AddressList of one or more complete mail addresses indicating who originally sent the message. All addresses listed in the From header are visible to the recipients of the message. msgTo contains an AddressList value of one or more complete mail addresses. The addresses identified in the msgTo header will each be sent an original copy of the message. Each recipient of the message will see any other mail addresses the message was delivered to. subject is a text value concisely describing the topic covered in detail by the message body. Note: By default, the subject and body of the message are encoded in UTF-8, which ensures that the characters sent will be interpreted correctly by almost all of the e-mail clients. If you want to use a specific character set, refer to the SMTP_SetPrefs and SMTP_Charset commands. message is a text value containing the body of the mail message. The optional sessionParam parameter sets the message format (standard text, HTML or Mime HTML) and the activation mode of the SSL protocol for the connection:
Note that these values correspond to usual combinations, however the sessionParam parameter is a actually a bit field and allows any custom combinations if you use Bitwise Operators:
The optional port parameter specifies the SMTP port number to use for connection with the server. The most frequently used values are:
The optional userName and password parameters are used to authenticate the sender with the mail server. These parameters must be passed together. Note that the most secure authentication mode supported by the server will be used (as with the default mode of the SMTP_Auth command). Here is an example of use of this command: $Host:="www.4d.com" Example for using the command to send a secure message through a MS Exchange server: $ServerName:="exchange.4d.com" Sending a message in HTML with SSL/TLS: $Host:="smtp.gmail.com" You saved a .mht document on your disk and want to send it by email. To do this, you can write: $Message:=Document to text("c:\\documents\\invitation.mht")
See also
|
PROPERTIES
Product: 4D Internet Commands
HISTORY
ARTICLE USAGE
4D Internet Commands ( 4D Internet Commands v16) |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||