Language
 
Information
Article ID41
Created On2/17/2010
Modified2/17/2010
PSCommerce - API - PSEmail
Usage:
Provides access to the .NET emailing libraries and PSCommerce sendMessage routines.

Properties:

  • Recipient [string]
  • Sender [string]
  • Subject [string]
  • CCList [string]
  • Message [string]
  • ReqReceipt [boolean]
  • ReqReciptTo [string]
Methods:

New([Recipient] as string, [Sender] as string, [ccList] as string, [Subject] as string, [Message] as string, [Recipt] as boolean, [ReceiptReplyAddress] as string)
Creates a new mail object based on the properties passed.

ccList can be passed as a ';' delimited list.

sendEmail([PSEmail] as PSEmail)
Sends an email using the local server SMTP based on the PSEmail object passed.

NB: A valid SMTP server must be set in the web.config section called  'PSSMTP', along with the 'PSEmailSignature' and 'PSEmailSender' settings

getPresetEmailText([FileName] as string)
Returns a text string of the .txt file held in the '~/PSCommerce/Admin/Emails/' folder.