 |
|
 |
Subject: Sending confidential email using VBA |
 |
 |
 |
Product Area: Notes Client |
 |
Technical Area: Specification |
 |
Platform: Windows |
 |
Release: 8.5.1 |
 |
Reproducible: -Reproducibility- |
 |
 |
 |
 |
I am sending the emails from MS Access using Lotus Notes.
Bot how could I send Confidential emails using VBA?
Right now the emails are being sent without encryption and they are not signed.
The source code:
'----------------------------------
Public Sub SendNotesMail(Subject As String, Attachment As String, Recipient As String, BodyText As String, SaveIt As Boolean)
Dim Maildb As Object 'The mail database
Dim UserName As String 'The current users notes name
Dim MailDbName As String 'THe current users notes mail database name
Dim MailDoc As Object 'The mail document itself
Dim AttachME As Object 'The attachment richtextfile object
Dim Session As Object 'The notes session
Dim EmbedObj As Object 'The embedded object (Attachment)
Set Session = CreateObject("Notes.NotesSession")
UserName = Session.UserName
MailDbName = Left$(UserName, 1) & Right$(UserName, (Len(UserName) - InStr(1, UserName, " "))) & ".nsf"
Set Maildb = Session.GETDATABASE("", MailDbName)
If Maildb.ISOPEN = Fasle Then
Maildb.OPENMAIL
End If
Set MailDoc = Maildb.CREATEDOCUMENT
MailDoc.Form = "Memo"
MailDoc.sendto = Recipient
MailDoc.Subject = Subject
MailDoc.Body = BodyText
MailDoc.DeliveryPriority = "H"
MailDoc.Encrypt = 1
MailDoc.Sign = 1
MailDoc.ReturnRecipiet = "1"
MailDoc.SaveMessageOnSend = True
If Attachment <> "" Then
Set AttachME = MailDoc.CREATERICHTEXTITEM("Attachment")
Set EmbedObj = AttachME.EMBEDOBJECT(1454, "", Attachment, "Attachment")
End If
MailDoc.PostedDate = Now() 'Gets the mail to appear in the sent items folder
MailDoc.SEND 0, Recipient
Set Maildb = Nothing
Set MailDoc = Nothing
Set AttachME = Nothing
Set Session = Nothing
Set EmbedObj = Nothing
End Sub
'----------------------------------
 
Feedback number WEBB8KDHXB created by ~Yentl Frokrobergobu on 08/03/2011

Status: Open
Comments:

Sending confidential email using VB... (~Yentl Frokrobe... 3.Aug.11)
. . Encrypt and Sign (~Umberto Kiluma... 4.Aug.11) |
|  |
|