You can access and examine clipboard data for copied Lotus Notes documents/design pieces to determine the nature...
of the content. What's more, you can match the Notes documents on the clipboard against existing documents, since they still have universal IDs intact.
The ability to check clipboard content can be useful when using queryPaste events to determine the nature of the content that's being pasted into the database. You can also use it as a temporary "dumping ground" for problem documents that you want to analyze using test agents -- without touching the original documents or modifying the test agent code.
Lotus Notes stores cut or copied documents and design pieces to a temporary database. To retrieve these documents, access a local temporary file called "~clipbrd.ncf" as a NotesDatabase object, and use this database's AllDocuments property. Here are two LotusScript code snippets, the first of which performs a copy/update to documents in the target database that have the same universal IDs.
The second code snippet opens the clipboard in the Lotus Notes user interface.
Note: You must add a form to the design -- or have documents with stored forms -- to fully open the documents. This exploits another undocumented feature, the UniversalID property of NotesView.
Do you have comments on this tip? Let us know.
This tip was submitted to the SearchDomino.com tip library by member Rodney Rear. Please let others know how useful it is via the rating scale below. Do you have a useful Lotus Notes, Domino, Workplace or WebSphere tip or code snippet to share? Submit it to our monthly tip contest and you could win a prize.