Hello, I need get attachment from a document 1 and need attach it in a other document 2. I create a buttom that search the first document, extract the attachment to hard disk and now need attach it in the document 2.
The next code is invalid but not show Error, It haven’t result.
I speack spanish and my english is bad, I hope you can understandme. Thanks
Dim Attach1 As NotesRichTextItem
Dim Attach2 As NotesRichTextItem
Set Attach1 = doc.GetFirstItem(“Adjunto”)
If Not Attach1 Is Nothing Then
HayAttach = Attach1.EmbeddedObjects
If Not Isempty(HayAttach) Then
Set Attach2 = docOther.GetFirstItem(“Adjunto”)
If Attach2 Is Nothing Then
Set Attach2 = docOther.CreateRichTextItem(“Adjunto”)
End If
Forall x In Attach1.EmbeddedObjects
If (x.Type = EMBED_ATTACHMENT) Then
p=Path + x.name
Call x.ExtractFile (p)
------->Call Attach2.embedObject(EMBED_ATTACHMENT, “”, p)
Kill p
End If
End Forall
End If
End If