I have a InDesign document with some images. Some images are linked from the path of indesign document and some images linked from other location. I want to copy those images to indesign document path which linked from other location and re-link all images.
I can update the all the link no issues with that. I got stuck to copy images if not linked from the indesign document path.
tell application "Adobe InDesign CS3"
set folderPath to (file path of document 1) as text
tell document 1
repeat with oneLink in (get links)
set linkPath to file path of oneLink
if linkPath is not (folderPath & name of oneLink) then
tell application "Finder" to set movedFile to (move file linkPath to folderPath) as alias
relink (contents of oneLink) to movedFile
Links also have the method ‘copy link’ with parameter new location. So you should be able to drop the Finder line.?
With using below code it moves the file from one place to another, but I want to copy the files so that original files will be there only.
tell application "Finder" to set MovedFile to (move file LinkedPath to myFolderPath) as alias
Exchange the command ‘move’ for ‘duplicate’