Indesign Search and Replace Link Paths

Have you ever tried renaming your server or moving your Indesign files to a new place and have all the links go missing? Your image files may have had a file path like:

ClientServer:Jobs2017:Brochure:Images:

and the new files have been moved to your archive server like this:

ArchiveServer:Jobs2017:Brochure:Images:

The filing structure is the same except that the address starts with “ArchiveServer” instead of “ClientServer”. However Indesign has no idea where to look for those links. Wouldn’t it be great if you could simply update the file path of every image, changing “ClientServer” to “ArchiveServer”? Well guess what? There is now.

This AppleScript adds a new “Search and Replace” function to Indesign. It searches and replaces text elements within the file paths of your placed images.

Enter the search and replace terms to search and replace elements from the link file paths

Every matching link will be updated to the new place. Note that this will only work if the folder structure is indeed the same after the server/folder name change. This is typically the case if you have renamed your server or moved a whole lot of folders to a new place on a server.

If the script does not find certain files in the expected location, they will be skipped. Files whose file paths do not contain the search term will not be affected. The script is highly specific and will only target the file paths where the search term is found. And it works very quickly.

You can run the Indesign Search and Replace Link Paths script and replace any segment of the file path – it doesn’t have to be the first part (parent directory). It can be any folder name or file name within the file path, even parts of a name. It can also be multiple folders. For example, if your original location was:

Earnest:Users:dm1:Desktop:Brochure:Images:

and your new location is

Archive1:2017_Jobs:Brochure:Images:

Simply enter those two folder paths into the search and replace fields remembering to keep the colons (:) in between each segment name. Search for “Earnest:Users:dm1:Desktop” and replace it with “Archive1:2017_Jobs”

Here’s how to use the script on file names. Imagine you have a whole lot of images with the suffix “_LowRes”. Then you make a whole set of new files with the suffix “_HighRes”. Use these two search and replace fields to update all images with “_LowRes” to the corresponding “_HighRes” file. In this case the files would all have to be in the same folder. If they are in a different folder, use the secondary search & replace (see details below).

Optional second search and replace fields

The script can now update files that have a different name and are also in a different folder.
For example your original files all end with “_LowRes” and are in the “Low Res Images” folder. The files you want to update to have the suffix “_HighRes” and are in the “High Res Images” folder. Use the new secondary search and replace feature to specify the change in folder location as well as the change in file name.

The two search & replace options are not limited to folders and files – they can be used on any part of the entire file path.

More options / tips

  • A new check box gives you the option to limit the search & replace to missing images only.
  • You can update files to their corresponding versions that have a different file extension. For example, change “.jpg” to “.tif”.
  • There is the option to process all open documents if you want to.
  • The script remembers the last search and replace terms you used so you don’t have to re specify them every time

A progress bar and conclusion message keep you informed of what is going on.

Note this is an AppleScript for using on a Mac. There is no PC version at the moment.

Download this script for $9.99

Technical support replies within 24 hours. Suggestions and customisations welcome. Free updates as they occur.

What if your folder hierarchies are messed up?

If your links are in a disordered state and you don’t really know where they are apart from somewhere within a top level folder which may contain hundreds or thousands of subfolders, you might do better with the Indesign Image Relinker Script also available at Dr Scripto. This will actually search through every subfolder, find your lost images and relink them to Indesign.

paypal_secure_crop_70pc

2 Comments

  1. Hi

    This scripts seems to nearly be something I need.
    Because I am in the progress of archiving a lot of InDesign jobs.

    But what I need is for the script to only change the path of images which are missing.
    Because some of the links (logos and other stuff) is in a general folder, where the files are not archived.

    I can not see this functionality in the description or am I missing something.

    Kind regards Jimmy Hartington

    Reply

Your email address will not be published.