I am trying to copy attachments from one form to another using a data input form which is not save, and all other field types I am able to pass except Rich Text. But I can not figure out the proper statement for rich text. I have tried CopyItemToDocument & CopyItem, but can not get either to work. Here is my shorten script:
Dim s As New notessession
Dim db As notesdatabase
Dim docT As notesdocument
Dim uiw As New notesuiworkspace
Dim uidoc As notesuidocument
Dim tcategory As String
Set db = s.currentdatabase
Set uidoc = uiw.currentdocument
Call uidoc.refresh
tcategory = uidoc.fieldgettext("tcategory"
Set docT = db.createdocument
With docT
.form = "todo"
.category = tcategory
Dim s As New notessession
Dim db As notesdatabase
Dim docT As notesdocument
Dim uiw As New notesuiworkspace
Dim uidoc As notesuidocument
Dim tcategory As String
Set db = s.currentdatabase
Set uidoc = uiw.currentdocument
Call uidoc.refresh
tcategory = uidoc.fieldgettext("tcategory"
Set docT = db.createdocument
With docT
.form = "todo"
.category = tcategory