I am attempting to copy an attached Word document from a Rich Text field on one document and paste multiple copies of it with different names in another document. For example, the original is "test.doc" and the copies are "test-1.doc," "test-2.doc" and "test-3.doc." Both documents reside in the same database.
QUESTION POSED ON: 24 FEB 2005
QUESTION ANSWERED BY: Andre Guirard
Since you're using the words copy and paste, I'm not certain whether you're talking about programming the task or doing it manually through the Notes UI.
In either case, the overall answer is the same. There's not a way to copy an attachment while at the same time renaming it. The only way to do this is to detach the attachment to disk, rename the disk file and then attach it to the new document.
If you want to automate the task in LotusScript, use NotesEmbeddedObject class, ExtractFile method to get the file onto disk. This lets you specify a different name from the source file. Use NotesRichTextItem.EmbedObject to create the attachment in the new document. Use the Name statement to rename the disk file to create differently named attachments.
|
 |
|