PDA

View Full Version : [SOLVED:] Word link to template



El_muchacho
05-30-2016, 05:44 AM
Hello, I need to create a link in a Word document(.docx) to a Word template(.dotm), these two documents are in the same file and this file must be able to move to another location or to another computer.
I tried hyperlinks but it opens directly the .dotm document and doesn't create a copy of it.
I tried a macro associated with a button but when I move my file, the link is broken.
Any solution ?
Thanks

El_muchacho
05-31-2016, 11:55 PM
I found the solution : I used the content of the macro and I put it directly into the function, I changed the link a little bit, I removed the first part of the link (file://C:\Users (file:///C:/Users)), it seems to work like that.

Private Sub CommandButton4_Click()
Documents.Add Template:="Part1\doc1.dotm" _
, NewTemplate:=False, DocumentType:=0
End Sub