9 Replies Latest reply on Oct 15, 2018 6:49 AM by CarlosCanto

    Batch Rename Sublayers

    roaris Level 1

      I have read through the documentation, and seen many scripts on here from Carlos and others. I simply want to rename all my sublayers of a layer to 'nopointer'. I have tried to 'hack' one of the scripts that renumber, etc. I simply cannot get it to work.


      I tried this as well:

      ////START SCRIPT////


      //how to use: select objects that you want to rename, then run script


      //note - new name may not display until you unselect objects



      var docRef = activeDocument;



      for (var i=0; i < docRef.pageItems.length; i++)




             if (docRef.pageItems[i].selected == true)




                     docRef.pageItems[i].name = "nopointer";






      But I think that was for objects (Even though I selected all the objects)


      Thanks in advance!