Create mail message with SendTo field set

I’m looking through the code in the Personal Address Book for the email address action hotspot to figure out how the hotspot works to create a new mail memo with the SendTo field set to the value of the hotspot. I am not terribly experienced in LotusScript, so forgive me if I am in error here, but it the CreateMailMemo agent seems appears to address multiple addresses/messages being created. I understand that it would also work for creating a single message, but the Options - Public references a “Mail Library” and I have no idea where/what this is. I’m just wondering if there is a more simple way to accomplish my objective since I’ll only be sending to one addresss at a time.

Thanks in advance for any input.

Subject: Put this code in a button or hotspot (it works for multiple addresses):

Dim session As New NotesSessionDim workspace As New NotesUIWorkspace

Dim uidoc As NotesUIDocument

Set uidoc = workspace.CurrentDocument

Dim doc As NotesDocument

Set doc = uidoc.Document

Dim item As NotesItem

If Not doc.yourfield(0) = “” Then

Set item = doc.GetFirstItem(“yourfield”)

Dim maildb As New NotesDatabase(“”, “”)

Call maildb.OpenMail

Dim mailnote As NotesDocument

Set mailnote = New NotesDocument(maildb)

Call mailnote.CopyItem(item, “SendTo”)

mailnote.Form = “Memo”

mailnote.Logo = session.GetEnvironmentString(“DefaultLogo”, False)

mailnote.Principal = session.UserName

Call workspace.EditDocument(True, mailnote)

End If

Subject: RE: Put this code in a button or hotspot (it works for multiple addresses):

Thank you very much!

-Megan

Subject: Create mail message with SendTo field set

You could put an action hotspot around the SendTo field (or any field you wanted for that matter). Then for the action, use the formula language @MailSend to send it.