Copy link to clipboard
Copied
JS how to split the object to two diffrent parts ,like this:
Copy link to clipboard
Copied
we're going to need more info about exactly what you're trying to do and the structure of your file so we can help plan for problems..
in it's simplest form, the code would go like this:
function splitParts()
{
var docRef = app.activeDocument;
var item1 = docRef.pathItems[0];
var item2 = docRef.pathItems[1];
item1.top = item1.top + 50;
item2.top = item2.top - 50;
}
splitParts();
Copy link to clipboard
Copied
sorry ,
the object have only one pathItems ,have not two pathItems .
Copy link to clipboard
Copied
As an options:
var s = selection[0],
i = s.pathItems.length,
obj = s.parent;
while ( i-- ) s.pathItems.moveToBeginning( obj );
s.remove();
Copy link to clipboard
Copied
can you send a sample file so we can see exactly what needs to be done?
Copy link to clipboard
Copied
https://yunpan.cn/cRYbfJK2sUvza
password: 5bec
Copy link to clipboard
Copied
up
Copy link to clipboard
Copied
up
Copy link to clipboard
Copied
please use google drive or dropbox or some other reputable file sharing service. no zip files
Find more inspiration, events, and resources on the new Adobe Community
Explore Now