View Single Post
 
Old 11-11-2022, 10:41 AM
Marcosnilsson Marcosnilsson is offline Windows 11 Office 2021
Novice
 
Join Date: Nov 2022
Posts: 3
Marcosnilsson is on a distinguished road
Default Word relative link to OLE objects from Excel

Hi!
I have been trying to understand the explanations about link of OLE objects in word documents and relative links (or re-link with macro after changing path) in several forums and posts, but I am not able to understand the solutions explained, even trying the macro solutions.
I will try to explain my problem clearly:
• I have a folder structure with word files that have pasted links to excel data from a single excel file located in a constant location in the same folder structure.
• The folder structure and files located inside have constant file names, but are copied to different locations (other folders for different projects).
• In the new location, excel file needs to be populated with different dada, and I need that the wor documents change links to this file.
I understand that this could be done making relative routes, or applying the macro attached in this post (coming from other post about the same topic), but I am not able to make it work.
I know that I could change one by one the source of every link, but I have like 10 word documents, and for every document like 20-30 linksÂ… so it is not practical to do it manually.
I provide attached an example of two folders that are directly located in my desktop:
• C:\Users\mnilsson\Desktop\A\AA\AAA
• C:\Users\mnilsson\Desktop\Location 1\A\AA\AAA
The word document with the links provided as example is named “M”
The part of the path that always keeps constant is: A\AA\AAA
The final goal is that using a macro, the file named “M”, located in folder “Location 1”, pick data from the excel file “A” located in the same foledr “Location 1” (currently, it takes them from excel file “A” located in folder “A” directly located in desktop.
Is It possible to write properly the macro, so it will works for me?
Could somebody copy the macro solution mentioned above, but populated with the data for the example provided, so I can see the data changed in macro, and then understood how to do it by myself?
If it works, I expect that in word file “M” located in folder structure “Location 1”, would have written:
• Location1
• Location2
• Location3
Instead of A1, A2, A3.
Thanks for your help, would be really appreciated!
Marcos
Attached Files
File Type: zip A.zip (29.6 KB, 3 views)
File Type: zip Location 1.zip (67.5 KB, 3 views)
File Type: zip AutoFldUpdt (1).zip (1.8 KB, 4 views)
Reply With Quote