This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal



Aug 3, 2011, 1:50 AM
6 Posts

Mail Sending

  • Category: Server Side JavaScript
  • Platform: Windows
  • Release: 8.5.2
  • Role: Developer
  • Tags:
  • Replies: 3
Dear All,
 
I am working on xpages application, this is my first application. Can anybody give me some idea? .How can i send a mail in xpages?
 
Thanks in Advance
Aug 3, 2011, 7:40 AM
261 Posts
Re: Mail Sending
You need to use the "send" method of the NotesDocument class.
 
Simple sample in SSJS:
 
var doc  = database.createDocument();
doc.replaceItemValue("Form", "Memo");
doc.replaceItemValue("Subject", "hello world");
doc.send("someone@somewhere.com");
 
 
Mark
Aug 3, 2011, 7:46 AM
170 Posts
Re: Mail Sending
 Sure, create a new notesdocument behind a button
 
var doc:NotesDocument=database.createDocument()
doc.replaceItemValue("Subject","Hello")
doc.replaceItemValue("Body","My Body")
doc.replaceItemValue("sendTo","person@test.com")
doc.send() 
Aug 3, 2011, 4:27 PM
6 Posts
Re: Mail Sending
Thanks Mark and Fredrik for ur response..  :)

This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal