Solved

Mail to selected names from a field...

Posted on 2004-04-13
5
223 Views
Last Modified: 2013-12-18
I have a field called "Names". This is a dialog list with multi values enabled.Now I want a button or a action which can send a mail with desired subject and body to the selected user from the Name field.

Pls help.
0
Comment
Question by:Prashantbhatnagar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 24

Accepted Solution

by:
HemanthaKumar earned 50 total points
ID: 10814752
Use @MailSend function

Syntax

@MailSend( sendTo ; copyTo ; blindCopyTo ; subject ; remark ; bodyFields ; [ flags ] )


~Hemanth
0
 
LVL 3

Expert Comment

by:xp_commander
ID: 10819870
Just incase , you need a sample code :-

Subject := "Subject goes here";
Message := "Body goes here";
@MailSend(Names; ""; "" ;Subject; Message; "");
0
 
LVL 19

Expert Comment

by:madheeswar
ID: 10820139
A sample code in Lotus Script:
Sub SendMailToRequestFromAdmin1
      Print "Submitting mail to approving person ..."
      Dim ws As New notesuiworkspace
      Dim uidoc As notesuidocument
      Dim doc As notesdocument
      Dim item As NotesItem
      Dim numvalues As Integer
      Dim session As New notessession
      Dim db As notesdatabase
      Dim maildoc As notesdocument
      Dim Body As NotesRichTextItem
      Dim hard As String
      
      Set db=session.currentdatabase
      Set uidoc=ws.currentdocument
      Set doc=uidoc.document
      tmpamount=Cstr(doc.grandtotal_n(0))
      
      'SEND MAIL TO DEPT HEAD.
      
      Dim item1 As notesitem
      Set item1 =doc.getfirstitem("staffname_x")
'      For y = 0 To Ubound(item1.values)
      Set maildoc = New NotesDocument( db )
      maildoc.Form = "Memo"
      If (uidoc.Fieldgettext("status_x")="Approved") Then
            maildoc.Subject ="Payment Voucher - Approved"
            Set Body=New NotesRichTextItem(maildoc,"Body")
            message="Your Payment Voucher for the items requested for the amount "+tmpamount+" has been approved. Thank you."
      End If
      If doc.status_x(0)="Pending" Then
            maildoc.Subject ="New Payment Voucher"
            Set Body=New NotesRichTextItem(maildoc,"Body")
            message="Please check the items requested to this month to your department for the amount "+tmpamount+". Thank you."
      End If
      If (uidoc.Fieldgettext("status_x")="Rejected") Then
            maildoc.Subject ="Payment Voucher - Rejected"
            Set Body=New NotesRichTextItem(maildoc,"Body")
            message="Your Payment Voucher for the items requested for the amount "+tmpamount+" has been rejected. Please make necessary amendmends and re-submit again.  Thank you."
      End If
      Call Body.AppendText(message)
      Call Body.AddNewLine(2)
      message1="Click here to open the form=========>>"
      Call Body.AppendText(message1)
      Call Body.AppendDocLink(doc,"Please click this link to open the document")
      Call Body.AddNewLine(2)
      mess="(This is an auto-generated email. You may delete this after review.)"
      Call Body.AppendText(mess)
      For y = 0 To Ubound(item1.values)
            hard=item1.values(y)+"@stoneforest.com.sg"
            Print "Submitted to : "+item1.values(y)
            
            Call maildoc.Send( True, hard)
      Next
      
      
End Sub
0
 

Author Comment

by:Prashantbhatnagar
ID: 10822169
Hi Hemanth,

Thanks a lot ...I never thought answer could be so simple..
Regards
0
 
LVL 24

Expert Comment

by:HemanthaKumar
ID: 10823647
That is why we are all here.. Keep It Simple !!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You’ve got a lotus Domino web server, and you have been told that “leverage browser caching” is a must do. This means that we have to tell the browser everywhere in the web to use cache. In other words, we set (and send) an expiration date in the HT…
Problem "Can you help me recover my changes?  I double-clicked the attachment, made changes, and then hit Save before closing it.  But when I try to re-open it, my changes are missing!"    Solution This solution opens the Outlook Secure Temp Fold…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

690 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question