Problem solve Get help with specific problems with your technologies, process and projects.

Add 'Copy as select table' command in LotusScript

Lotus Notes has command, "Copy as select table." Is it possible to add this command in LotusScript? If it is, then how would I do this? Thanks!

View member feedback to this Ask the Expert Q&A.

Currently, there is no built-in method to mimic the "Copy selected as table" functionality. However, you can mimic it by creating a view action that triggers an agent that gets a collection of selected documents, navigates to wherever you need to paste the data, and then uses the new NotesRichText classes in R6 to construct a table with the view data.


I have a view called "WhoWillBe" that I want to send by e-mail. This e-mail actually will be sent by an automatic agent. The Copy Selected as Table button is great and it's just what I need, however, I don't want to do the Create new memo and then paste this by myself, I want an agent to do it. Could you bring me some code examples on how can I accomplish that?

—Beatriz R.


I believe that what Beatriz is trying to do is beyond the scope of that simple function. It may be possible with a few @Formulas in the front-end, but it's not likely. In this case, she may need to use LotusScript to read the contents of a view and build a table with LotusScript's rich text classes. This is certainly doable, but beyond the scope of a simple tip. I would refer Beatriz to the documentation to use the NotesView class to loop through the contents of a view and the NotesRichText classes to dynamically build a table in a new mail memo document.

Brad Balassaitis

Do you have comments on this Ask the Expert question and response? Let us know.

Dig Deeper on LotusScript

  • Favorite iSeries cheat sheets

    Here you'll find a collection of valuable cheat sheets gathered from across the iSeries/ community. These cheat ...