PasteFromClipboardWithPattern Method
Description
This pastes a mirrored pattern of a copied feature or group of features that are stored in the Clipboard. It pastes the feature or features at the current insertion point location using the pattern mirror defined in the SetPasteWithPatternMirror method.
Syntax
Visual Basic |
---|
Public Sub PasteFromClipboardWithPattern() |
Example
This example shows how to set a command as the current commmand, how to select it, copy it, set the insertion point to the end of the measurement routine and then paste the selected command.
PCDLRN.Application app = new PCDLRN.Application(); PCDLRN.PartPrograms prgs = app.PartPrograms; PCDLRN.PartProgram prg = prgs.Open("ClipboardOperationsExample.PRG", "Offline"); PCDLRN.Commands commands = prg.Commands; PCDLRN.Command cmd = commands.Item("CIRC1"); PCDLRN.Command cmd2 = commands.Item("CIRC2"); prg.EditWindow.CommandMode(); commands.SetCurrentCommand(cmd); prg.EditWindow.SelectCommand(); commands.SetCurrentCommand(cmd2); prg.EditWindow.SelectCommand(); prg.EditWindow.SetPasteWithPatternMirror(2); // flip by Y prg.EditWindow.CopySelectedToClipboard(); commands.InsertionPointAfter(commands.LastCommand); prg.EditWindow.PasteFromClipboardWithPattern();
See Also