Re-attach files in links
Hello,
I am looking for a way to re-attach links to items in my Zotero collections. For example, I have an item in the library called "Test". Within Test is an attachment called Test_file.pdf. All of my attachments (including Test_file.pdf) are in a base directory, which I have specified in the Files and Folders section of Zotero' Preferences. It appears that just having the file in the right place and having an attachment with the identical file name is not enough for the attachment file to be linked to the Zotero library entry. That is, when I click on the attachment from the library, I still receive the prompt to locate the file. As soon as I help Zotero re-locate the file then it of course opens just fine.
Is there a way to have Zotero look right where I'm telling it to for the attachments and compare against the filenames listed for the Attachment file and re-attach in an automated way? I have about 400 entries like this.
Thanks
I am looking for a way to re-attach links to items in my Zotero collections. For example, I have an item in the library called "Test". Within Test is an attachment called Test_file.pdf. All of my attachments (including Test_file.pdf) are in a base directory, which I have specified in the Files and Folders section of Zotero' Preferences. It appears that just having the file in the right place and having an attachment with the identical file name is not enough for the attachment file to be linked to the Zotero library entry. That is, when I click on the attachment from the library, I still receive the prompt to locate the file. As soon as I help Zotero re-locate the file then it of course opens just fine.
Is there a way to have Zotero look right where I'm telling it to for the attachments and compare against the filenames listed for the Attachment file and re-attach in an automated way? I have about 400 entries like this.
Thanks
So the question becomes, how do I have Zotero change the filenames of each of these 400 links to be \relative_base_directory\existing_filename.pdf from what it is now as c:\absolute_directory\existing_filename.pdf ?
Thanks.
Alternatively, I believe Zutilo, a third-party plugin, can modify absolute paths directly in batch.
So, e.g., if you have a file with a path set to c:\foo1\bar.pdf, but the file exists at c:\foo2\bar.pdf, you can set c:\foo1\ as the base directory, which will change the path to the relative path "bar.pdf". If you then change the base directory to c:\foo2, the file will be found.
As a result of this null-path scenario. I cannot provide an "old" path, which is the first step of changing the path using Zutilo. I've tried leaving it blank, but then it just exits and doesn't ask for a new path. I've also tried the usual old-path suspects ("attachments:" "\" "/" "c:\users\...\"), which at least gets me to the second dialog box where I enter the new path, but the new path never takes over.
This issue applies only to a sub-set of the library, because I accidentally removed any path using this same Zutilo path change tool (before I knew what I was doing).
Any ideas?
The 2nd approach you provided in your 2nd post didn't seem to help with this.