Copy link to clipboard
Copied
I have a 200+ page indesign document and inported multiple AI fileusing PLACE command. Now I want to use same indesign document to place differant AI files. My new AI files have differant no of artboards than the previouse AI files I used, so i can not use Relink option.
So how can i delete/unlink my previously Placed files that i don't have content of those files in Indesign file.
Ok, now I understand the problem. I don't think there is anything inbuilt to achieve this. I quickly put up a script that can help you. See the following, just change the values of the linkName array to the name of the links that you want to delete and it should get it done, The link name can be seen in the links panel, it is generally the file name
var linkName = ["download1.jpeg", "app1496256.pdf"]
for(var i =0; i < linkName.length; i++)
{
var ln = app.documents[0].links.itemByName(linkName[i
...
Copy link to clipboard
Copied
Are you not able to select the object showing the content of AI file on the INDD document? If yes just select and click delete to remove the object and the link from your document. You can select using the layer panel as well, and also use the links panel, just right click the link and select Go To Link, then hit delete button to delete the object
-Manan
Copy link to clipboard
Copied
Well reason for asking the question was i do not want to delete one by one.
All the methods u r describing are basically delete one by one from 200 + pages.
So i thought may there is a way that one can do it say with click of a button
Copy link to clipboard
Copied
Ok, now I understand the problem. I don't think there is anything inbuilt to achieve this. I quickly put up a script that can help you. See the following, just change the values of the linkName array to the name of the links that you want to delete and it should get it done, The link name can be seen in the links panel, it is generally the file name
var linkName = ["download1.jpeg", "app1496256.pdf"]
for(var i =0; i < linkName.length; i++)
{
var ln = app.documents[0].links.itemByName(linkName[i])
while(ln.isValid == true)
{
ln.parent.parent.remove()
ln = app.documents[0].links.itemByName(linkName[i])
}
}
-Manan
Copy link to clipboard
Copied
Hi I save this code as ",jsx" file. but in script panel it is greyed out and i can see a "i" symbol next to it. when I bring mouse over on the it in the script panel it says
"This file is not executable by any supported language".
Copy link to clipboard
Copied
".jsx" - "." not ","
Copy link to clipboard
Copied
So it's pretty much the same - or even more time consuming - as clicking each link on Links panel and then deleting it 😉
I think the better way would be to delete all ".ai" files in bulk ?
Copy link to clipboard
Copied
Which editor did you use to create this jsx file?
-Manan
Copy link to clipboard
Copied
i am using mac(OS Catalina) and used texteditor and made sure that its plain text not rich text.
Copy link to clipboard
Copied
Compare the permissions of the file you created and the one's that work? If it still does not work then upload the file on Dropbox and share the link here, i will see if it runs on my MAC or not?
-Manan
Copy link to clipboard
Copied
ok thank you for the script it works. it just gived=s this messgae at end
just want to understand why i am geting this error and how to stop this. It could be because of my file because i have a linked file that is behaving strangely. I will post question about it.
Copy link to clipboard
Copied
I had the same problem. I used
myPDFPage.parent.remove();
and now it works