This content has been marked as final.
Show 2 replies
-
1. Re: Need to global find and scale and resize frame on a linked graphic
-hans- Mar 21, 2013 11:58 AM (in response to E Diane King)Give it a try
#target Indesign var toSearch = 'example.ai' //to edit: name of the ai to work on //select a folder with inddFiles var selFolder = Folder.selectDialog(); if(!selFolder) {exit();}; var allInddFiles = selFolder.getFiles('*.indd'); app.scriptPreferences.userInteractionLevel = UserInteractionLevels.NEVER_INTERACT; for(var i = 0; i < allInddFiles.length; i++) { currItem = allInddFiles[i]; var currDoc = app.open(currItem); changeAI(currDoc); } app.scriptPreferences.userInteractionLevel = UserInteractionLevels.INTERACT_WITH_ALL; function changeAI(docRef) { var currGraphics = docRef.allGraphics; l = currGraphics.length; while(l--){ currGraphic = currGraphics[l]; var currName = currGraphic.itemLink.name; if(currName == toSearch){ currGraphic.horizontalScale = 30; currGraphic.verticalScale = 30; currGraphic.parent.fit(FitOptions.FRAME_TO_CONTENT) } } currDoc.close(SaveOptions.YES); } -
2. Re: Need to global find and scale and resize frame on a linked graphic
E Diane King Mar 21, 2013 12:26 PM (in response to -hans-)You, my friend, are a life saver! Thanks so much, Hans.


