Copying a layer

Copying a layer
 1# for this example you need two drawings open
 2# the active layer of the first drawing is copied
 3# to the second drawing
 4
 5# get the active layer of the first drawing
 6source_layer = impact.drawings.item(1).active_layer
 7
 8# get the second drawing
 9destination_drawing = impact.drawings.item(2)
10
11# do the copy
12new_layer = source_layer.copy_to_drawing(destination_drawing, "")
13
14if new_layer is not None:
15    impact.gui.output_toolbox.add(new_layer.full_name)
16else:
17    impact.gui.output_toolbox.add("the copy failed")
18