I have a text document with a textframe. I want a macro who creates 11 clones of the textframe on the same page. The macro selects the frame, but when pasting it, the original frame gets overwritten. How can I programmatically deselect my selected frame, so that the paste operation creates a second copy ?
Here the code I have:
frame = thisdoc.textframes.getbyIndex(0) ' select text frame
controller.select(frame)
dispatcher.executeDispatch(docframe1, ".uno:Copy", "", 0, Array()) ' copy it
'here I need something to deselect the frame
dispatcher.executeDispatch(docframe1, ".uno:Paste", "", 0, Array()) 'paste clipboard into it