![]() |
|
#1
|
|||
|
|||
![]()
Im trying to find the middle node on curves which have only one sub-path but a variable number of nodes, and then split the curve into two objects but struggling with syntax - I first check to see there are at least 3 nodes and then
Code:
Set sh = sr.Shapes(n) ndCnt = sh.Curve.Nodes.All.Count ndSplit = Int(ndCnt \ 2) Set nr = sh.Curve.Node(ndSplit) nr.BreakApart nr.RemoveAll srBrokenCurves.AddRange sh.BreakApartEx EDIT: This works Code:
ndCnt = sh.Curve.Nodes.Count 'check there are at least 3 If ndCnt > 2 Then 'set the node to be split on ndSplit = Int(ndCnt \ 2) + 1 Set nd = sh.Curve.Nodes(ndSplit) nd.BreakApart Last edited by nic; 13-03-2016 at 14:12. |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
break until single character | nikhiscd | CorelDRAW/Corel DESIGNER VBA | 3 | 22-06-2008 04:26 |
AtisicMediaGroup shape can't break? | mitchellhu | CorelDRAW/Corel DESIGNER VBA | 2 | 04-12-2007 19:28 |
Break Each Object Apart within Selection | geopig | CorelDRAW/Corel DESIGNER VBA | 2 | 15-04-2005 13:38 |
Gradient + Break Apart | Hernán | New product ideas | 6 | 25-04-2004 14:34 |
+ Break Apart | Hernán | CurveWorks | 1 | 15-02-2004 16:49 |