View Single Post
  #8  
Old 05-05-2012, 10:32
FaneDuru FaneDuru is offline
Member
 
Join Date: May 2012
Posts: 35
Default

This code works too. You need to name the shape which must be copied (on the cdr file):
Code:
Dim al As Layer

Optimization = True

Set al = ActiveLayer
With al
    .Import ("sourcefile.cdr")
    .Shapes.First.Ungroup
    .Shapes.AllExcluding("Test", "Rect_test").Delete
End With

Optimization = False
Inside the excluding paranthesis in case you have on the active layer some other shapes, these must also be here...
Reply With Quote