Results 1 to 10 of 10
  1. #1
    3 Star Lounger
    Join Date
    Mar 2006
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    289
    Thanks
    0
    Thanked 1 Time in 1 Post

    HTML email using Lotus Notes (2003 SP2)

    Has anyone been able to send a Lotus email using VBA which included a hyperlink in the body of the email and not have the email display the link as plain text?
    Thanks
    chuck

  2. #2
    5 Star Lounger
    Join Date
    Aug 2004
    Location
    Connecticut, USA
    Posts
    816
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: HTML email using Lotus Notes (2003 SP2)

    Do you mean the link is coming across as plain text and you want it to be a link of the other way around. It's a link and you want it to be plain text.

    If it's the former: if you are editing the email, Lotus notes does not make the link active. With LN, the link is active only in a non editing mode - such as the sent document or the received document.

    I've never used Access to send an email using LN with a hyperlink in it. Do you have an example of the code, and I could try to reproduce your results?

  3. #3
    5 Star Lounger
    Join Date
    Aug 2004
    Location
    Connecticut, USA
    Posts
    816
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: HTML email using Lotus Notes (2003 SP2)

    <P ID="edit" class=small>(Edited by mbarron on 29-Oct-07 12:10. Added some white space after the DoCmd line)</P>I used a SendObject of:

    DoCmd.SendObject acSendQuery, "Query1", acFormatXLS, "AnyAddress@SomeDomain.com", , , "Test of Send", "Goto http://www.google.com"

    that displays the link as a link at my gmail accont and when I receive it in Lotus Notes. During the edit in Lotus Notes, the link is "dead".

    One note - the http:// was necessary to make the link active when receiving in Lotus Notes. Without it, the link is not a link, only text.

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: HTML email using Lotus Notes (2003 SP2)

    There is no space before or after the URL, this might make it too difficult for Lotus Notes to decide where the URL begins and ends.

  5. #5
    3 Star Lounger
    Join Date
    Mar 2006
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    289
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: HTML email using Lotus Notes (2003 SP2)

    Space made no difference. Oddly enough, when I forward the note to another Lotus mailbox the link is active.

    Our Lotus Notes Engineer is also looking into it, though he believes it is an Access issue.
    Thanks
    chuck

  6. #6
    3 Star Lounger
    Join Date
    Mar 2006
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    289
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: HTML email using Lotus Notes (2003 SP2)

    Here is the code I have been using.

    Function SendLotusEmail()

    Dim Subject As String
    Dim Attachment As String
    Dim Attachment2 As String
    Dim Recipient As String
    Dim BodyText As String
    Dim SaveIt As Boolean
    Dim dbs As Database

    'This function will send a mail and attachment if neccessary to the recipient including the body text.
    'Requires that notes client is installed on the system.

    'Set up the objects required for Automation into lotus notes
    Dim Maildb As Object 'The mail database
    Dim MailDoc As Object 'The mail document itself
    Dim Attach1 As Object 'The attachment object
    Dim Attach2 As Object 'The second attachment
    Dim Session As Object 'The notes session
    Dim EmbedObj As Object 'The embedded object (Attachment)

    'Start a session to notes
    Set Session = CreateObject("Notes.NotesSession")
    Set Maildb = Session.GETDATABASE("", "")

    'Set the message for the BodyText
    'BodyText = BodyText & vbCrLf
    BodyText = "THE ATTACHED FILES CONTAINS SENSITIVE CLIENT INFORMATION AND SHOULD NOT " _
    & "BE SENT OUTSIDE OF PNC UNLESS ENCRYPTED. PNC HAS AN INTRANET SITE, " _
    & "SecureExport, DESIGNED FOR END USERS TO SEND E-MAILS WITH ENCRYPTED ATTACHMENTS. THE " _
    & "FOLLOWING IS THE LINK TO SecureExport:" _
    & "https://secureexport.abc.com/sswebsite/encrypt.nsf/mainform?OpenForm" _
    & "SecureExport IS A WEB-BASED FILE ENCRYPTION SERVICE THAT ALLOWS YOU TO ENCRYPT FILES IN JUST " _
    & "A FEW EASY STEPS. IT IS IMPORTANT TO REMEMBER THAT FILE ENCRYPTION ONLY ENCRYPTS THE FILE " _
    & "ATTACHMENTS, NOT THE E-MAIL TEXT."

    Maildb.OPENMAIL

    'Set up the new mail document
    Set MailDoc = Maildb.CREATEDOCUMENT
    MailDoc.Form = "Memo"
    MailDoc.sendto = "charles.rau@pnc.com"
    'MailDoc.copyto = ""
    MailDoc.Subject = "Chart Reports"
    MailDoc.Body = BodyText
    MailDoc.SAVEMESSAGEONSEND = SaveIt

    'Attachment = "PPNWWS07VOL1GROUPPATOSTOP Technical Services" _
    & "MercantileBakery & Confectionery UnionPensionChart.pdf"
    'Attachment2 = "PPNWWS07VOL1GROUPPATOSTOP Technical Services" _
    & "MercantileBakery & Confectionery UnionHealthChart.pdf"

    'Set up the embedded object and attachment and attach it
    'Set Attach1 = MailDoc.CREATERITHTEXTITEM("Attachment")
    'Set EmbedObj = Attach1.EMBEDOBJECT(1454, "", Attachment, "Attachment")
    'Set Attach2 = MailDoc.CREATERICHTEXTITEM("Attachment2")
    'Set EmbedObj = Attach2.EMBEDOBJECT(1454, "", Attachment2, "Attachment2")

    'Send the document
    MailDoc.PostedDate = Now() 'Gets the mail to appear in the sent items folder
    MailDoc.SEND 0, Recipient

    'Clean Up
    Set Maildb = Nothing
    Set MailDoc = Nothing
    Set Attach1 = Nothing
    Set Attach2 = Nothing
    Set Session = Nothing
    Set EmbedObj = Nothing
    Set dbs = Nothing
    MsgBox "Email sent"
    End Function
    Thanks
    chuck

  7. #7
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: HTML email using Lotus Notes (2003 SP2)

    I don't think this has anything to do with Access. Your code uses the Lotus Notes API to generate an e-mail; this might as well have been done in Excel or in VB6. Only the data come from Access, but that has no bearing on whether an URL becomes a clickable link or not.

  8. #8
    3 Star Lounger
    Join Date
    Mar 2006
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    289
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: HTML email using Lotus Notes (2003 SP2)

    You may be right Hans. You know I am over my head here. I have found many are looking for a solution. I have searched the internet and other Access forums only to find similiar questions to mine with no solution at this point, but I will keep looking. If our Lotus Notes people find a fix I will post back.
    Thanks
    chuck

  9. #9
    3 Star Lounger
    Join Date
    Mar 2006
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    289
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: HTML email using Lotus Notes (2003 SP2)

    HyperSpace...the final frontier. I was having issues sending to multiple recipients and in testing different syntax I added a semicolon to the end of the email address and low and behold my hyperlink is active.
    Thanks
    chuck

  10. #10
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: HTML email using Lotus Notes (2003 SP2)

    Great! <img src=/S/thumbup.gif border=0 alt=thumbup width=15 height=15>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •