Example: copy method

This example copies a range and pastes it to another range.

  Range range = sheet.range("A1:B2");
  range.setText("copy");
  range.copy();
  Range range2 = sheet.range("C1:D2");
  range2.paste();

Related information

copy method

paste method