• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

UNLINKING SYMBOLS INSTANCES

Community Beginner ,
Nov 01, 2010 Nov 01, 2010

Copy link to clipboard

Copied

hI,

I would like to unlink all symbols instances used in a file.

I have tried something that does not work. The script does not unlink because I am stuck at this step.

#target illustrator


var doc=activeDocument;

UnlinkAll(doc);
function UnlinkAll(doc){
     var SLen=doc.symbols.length-1;
     for (si=SLen;si>-1;si--){
   alert(doc.symbolItems.getByName(doc.symbols[si])) ;

     return true;
     }
}

JPD

TOPICS
Scripting

Views

3.5K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Guide ,
Nov 02, 2010 Nov 02, 2010

Copy link to clipboard

Copied

Is there a method for 'Unlinking' symbol instances?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 02, 2010 Nov 02, 2010

Copy link to clipboard

Copied

Not that I can see.


Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Nov 02, 2010 Nov 02, 2010

Copy link to clipboard

Copied

I even checked in the scripting docs for newer versions that what I have and nothing had changed… In the GUI you could remove the symbol from the palette but you would be prompted for how you wish to handle it… I have not tried this with script and dialogs off…

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 02, 2010 Nov 02, 2010

Copy link to clipboard

Copied

The Scripting Help lists both Symbol and SymbolItem -- but neither of them has 'unlink', or something synonymous ...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 02, 2010 Nov 02, 2010

Copy link to clipboard

Copied

not an "unlink" method but...

Illustrator.ActiveDocument.Symbols("SymbolName").Delete

will unlink all instances automatically

if you must preserve the symbol duplicate it first, save its name, then rename the duplicate

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Nov 03, 2010 Nov 03, 2010

Copy link to clipboard

Copied

In fact the following script  seems to do the job. It  unlink the instan

ces while removing the symbols in the symbols palette. I could not make the Delete 'thing' work.

I dont know if it is possible to unlink and keep the symbols.


#target illustrator


var doc=activeDocument;

VectorizSymbols All(doc);
function VectorizSymbolAll(doc){
     var SLen=doc.symbols.length-1;
     for (si=SLen;si>-1;si--){
doc.symbols[si].remove();
}
     return true;
}


JPD

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 03, 2010 Nov 03, 2010

Copy link to clipboard

Copied

oh, sorry I should have mentioned the sample code is in VBA, the sintax is a little different. Let me try to do the delete "thing" in JS...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 03, 2010 Nov 03, 2010

Copy link to clipboard

Copied

LATEST

here it is

#target illustrator


var doc=activeDocument;

VectorizSymbolAll(doc);
function VectorizSymbolAll(doc){
     var SLen=doc.symbols.length-1;
     for (si=SLen;si>-1;si--){
         var symbolName = doc.symbols[si].name
         doc.symbols[si].duplicate(doc, ElementPlacement.PLACEATBEGINNING);
         doc.symbols[si].remove();
         doc.symbols[symbolName + " 1"].name = symbolName
}
     return true;
}

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines