Printing attachments in the protected area of a form.
Posted on 2006-05-18
We receive Faxes from a Right Fax server into our Lotus Notes inbox. We need an agent that will print the fax attachments without having to individually open each email. The problem, however, is that the faxes are not attached to the email "Body" but are in a "protected area of the form", thus, the normal method of creating a rich text navigator will not work. The below code being an example:
Dim rtitem As notesrichtextitem
If doc Is Nothing Then Exit Sub
If doc.HasItem ("Body") = False Then Exit Sub
Set rtitem = doc.GetFirstItem( "Body" )
If ( rtitem.Type = RICHTEXT ) = False Then Exit Sub
If Isempty(rtitem.EmbeddedObjects) Then Exit Sub
Forall o In rtitem.EmbeddedObjects
If ( o.Type = EMBED_ATTACHMENT ) Then
Call PrintAttachment (o)
I do not know how to get at the attachments if they are not in the email body. When I throw the Lotus Script in debug, I can see the attachments in the document as $FILE items, but they are NotesItems, not rich text items, which leaves me without the embeddedobjects method. I am at a loss for what to do? Thank you.