By submitting your email address, you agree to receive emails regarding relevant topic offers from TechTarget and its partners. You can withdraw your consent at any time. Contact TechTarget at 275 Grove Street, Newton, MA.
This agent will allow you to create an email with HTML formatting as an attachment to your email message.
Put this code inside of an agent, and have a directory on a server where a temporary file can be created and written to.
Dim object As notesembeddedobject Dim htmlmsg As String Dim tempDir As String Dim fileNum As Integer 'create html attachment htmlmsg = "" fileNum% = Freefile() tempDir$ = Environ("Temp") 'Messagebox tempDir$ Open tempDir$ &"newsletter.htm" For Output As fileNum% 'Create standard HTML header and titles htmlmsg = htmlmsg & |<html>| htmlmsg = htmlmsg & |<head>| htmlmsg = htmlmsg & |<Title>BlueCuda Newsletter</title>| htmlmsg = htmlmsg & |</head>| htmlmsg = htmlmsg & |<body>| Print #fileNum%, htmlmsg htmlmsg ="" 'close html standard tags and embed the attachment htmlmsg = htmlmsg & |</body>| htmlmsg = htmlmsg & |</html>| Print #fileNum%, htmlmsg Close fileNum% Set object = rtitem.embedobject(EMBED_ATTACHMENT, "", tempDir$ &"newsletter.htm")