1
votes

I can't find a way to copy selected documents to buffer using standard classes in LotusScript. Is it possible to do it?

@Command([EditCopy])

The problem with command/formula - is more difficult to debug/log errors etc, so I wish to re-write action to LotusScript if possible.

I can make a solution via Java and then wrap it into LS2J, but it looks to complicated for such simple operation.

1

1 Answers

1
votes

You can't copy selected documents to clipboard with standard LotusScript Notes classes.

NotesUiDocument.Copy() doesn't help you neither as it copies only selected parts of an open document.

I would stay with @Command([EditCopy]). If it's really worth it to move the formula code to LotusScript I would separate @Command([EditCopy]) in an agent and call it from your new LotusScript code.

But, the question is, what is the goal to copy selected documents to clipboard? It will be a Notes Client specific kind of clipboard content. You can only use it in Notes Client itself to copy the documents into the same or another database. So, why not use "normal" LotusScript methods to copy documents like NotesDocument.CopyToDatabase or NotesDocument.CopyAllItems?