我有一封传入的电子邮件(mail-in db),其中包含一个 RichTextField,其中找到了“一些”附件。我还发现附件不是在 RTF 中,而是在文档中作为 $FILE。我正在尝试处理所有对象以将它们复制到另一封传出电子邮件。我可以使用下面的代码找到 $FILE。
Dim rtiObject as NotesEmbeddedObject
Dim rti_Email as NotesRichTextItem
Dim obj_Email as NotesEmbeddedObject
ForAll p in mailDoc.items
if p.Name = "$FILE" then
set obj_Email = mailDoc.GetAttachment(p.Values(0)) 'this will return the Name of the attachment (or file)
set rtiObject = rti_Email.EmbedObject( EMBED_ATTACHMENT, "", obj_Email.Name) 'this is supposed to attach the file to the document's RTF
End If
End ForAll
当此脚本运行时,它会找到 $FILE 文件并返回名称但不返回对象,我无法从那里对其进行任何处理。
我需要做什么才能从原始文档中获取附件/对象 ($FILE) 并将其附加到外发电子邮件中的 RTF?
我曾考虑将附件分离到网络,然后将其附加到外发电子邮件,然后从网络中删除附件,但这似乎不切实际。
有没有更好的方法来处理传入电子邮件中的这些 $FILE 类型的附件,这会使这更容易?