Firstly, happy birthday (33!! mind how you go!!!!! I can't even remember that
far back). have a good 'un
I am using your HTML mail code and have found it extremely useful on 2 or 3
projects already. One thing I'm trying to do though is create the mail with the
code and then display it using ws.editdocument before sending it (for proof
reading and addition of any other text if required). Now the content comes
through as I would expect (nicely formatted tables etc..), but when I send it ,
the recipient only gets the 'textual' representation of the mail (with the text
tables and the content all over the place.)
So, the question is, is there a way to keep the formatting once I send it from
my client?
Just as an aside - while using this, I needed to turn of the auto insertion of
my mail signature as it was putting it above the text rather than below it. The
code I came up with may be useful for others (there may be another way but
this works)..
Sub toggleSignature(session As NotesSession,onoff As String)
Dim db As Notesdatabase
Dim mdb As New NotesDatabase( "", "" )
Dim profile As NotesDocument
Call mdb.OpenMail
Set db = session.currentdatabase
Set profile = mdb.getProfiledocument("CalendarProfile")
If Not (profile Is Nothing) Then
Select Case onoff
Case "1"
profile.EnableSignature = "1"
profile.SignatureOption="2"
Case "0"
profile.EnableSignature = "0"'
profile.SignatureOption="0"
End Select
Call profile.Save(True,False)
End If
End Sub
This I use either side of 'your' sendMessage code.
Call toggleSignature(Session,"0") 'turn off signature
Call sendMessage(vdocument.SendTo(0), subject, htmltext, plaintext)
Call togglesignature(Session,"1")'turn on signature
Hi Jake et al
Firstly, happy birthday (33!! mind how you go!!!!! I can't even remember that far back). have a good 'un
I am using your HTML mail code and have found it extremely useful on 2 or 3 projects already. One thing I'm trying to do though is create the mail with the code and then display it using ws.editdocument before sending it (for proof reading and addition of any other text if required). Now the content comes through as I would expect (nicely formatted tables etc..), but when I send it , the recipient only gets the 'textual' representation of the mail (with the text tables and the content all over the place.)
So, the question is, is there a way to keep the formatting once I send it from my client?
Just as an aside - while using this, I needed to turn of the auto insertion of my mail signature as it was putting it above the text rather than below it. The code I came up with may be useful for others (there may be another way but this works)..
Sub toggleSignature(session As NotesSession,onoff As String) Dim db As Notesdatabase Dim mdb As New NotesDatabase( "", "" ) Dim profile As NotesDocument Call mdb.OpenMail Set db = session.currentdatabase Set profile = mdb.getProfiledocument("CalendarProfile") If Not (profile Is Nothing) Then Select Case onoff Case "1" profile.EnableSignature = "1"
profile.SignatureOption="2" Case "0" profile.EnableSignature = "0"' profile.SignatureOption="0" End Select Call profile.Save(True,False) End If End Sub
This I use either side of 'your' sendMessage code.
Call toggleSignature(Session,"0") 'turn off signature Call sendMessage(vdocument.SendTo(0), subject, htmltext, plaintext) Call togglesignature(Session,"1")'turn on signature
Cheers
Lee