Copyitemtodocument

Good Day All!!!

I am trying to obtain a gif signature in a document and append it to another. I have tried AppendRTItem and copyitemtodocument neither works. I get the handle on the image however it does not append to the rich text field.

This is part of my code. I have searched the forum and worked on this for several days. I am at the point of going to electronic signature.

Dim se As New NotesSession

Dim w As New NotesUIWorkspace

Dim uidoc As notesuidocument

Dim db As NotesDatabase

Dim dc As notesdocumentcollection

Dim signview As notesview

Dim rt1 As NotesRichTextItem

Dim rt2 As NotesRichTextItem

Dim skey(0) As String

Dim doc As NotesDocument 'insert rt here

Dim signdoc As NotesDocument 'contains the richtext to be inserted

Dim curdate As New NotesDateTime(Now())

Set db =se.CurrentDatabase

Set uidoc = w.CurrentDocument

Set doc = uidoc.Document

Set signview =db.getview(“sign”)

skey(0) = “HR1”

Set signdoc = signview.GetDocumentByKey (skey )

Set rt1 = signdoc.GetFirstitem(“sign”)

If Not ( rt1 Is Nothing ) Then

Set rt2 = doc.GetFirstItem(“HRSignature”)

Call rt2.AppendRTItem( rt1 )

doc.HRDate = Cdat(curdate.DateOnly)

Call doc.Save(True, False)

End If

'Call rt1.copyitemtodocument(doc, “HRSignature”)

Any ideas would be appreciated.

Thanks!!! Terri

Subject: copyitemtodocument

I think you are trying to append an item, when actually you want to embed an object. I think that’s the key. You need to embed the object.