Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 09-16-2024, 04:13 AM
jparnold jparnold is offline Include a 'wild'  filename and location in document Windows 10 Include a 'wild'  filename and location in document Office 2010 32bit
Advanced Beginner
Include a 'wild'  filename and location in document
 
Join Date: Jan 2012
Location: Blue Mountains, NSW, Australia
Posts: 41
jparnold is on a distinguished road
Default Include a 'wild' filename and location in document

I know how to add the current filename and file location in a Word document however is it possible to add the filename and location which is updated wherever the file is located if it changes in the future eg the Word document current resides (say) at F:/my_documents and that is printed when the document is printed and then I decide to move the Word file to (say) G:/johns_documents and I want it to automatically print g:/hohns_documents instead of f:/my_documents.




Another question would be is it possible to create a Word 'form' which contains information that gets translated into the filename I give it and the location I save it to?
Reply With Quote
  #2  
Old 09-16-2024, 05:22 AM
Charles Kenyon Charles Kenyon is offline Include a 'wild'  filename and location in document Windows 11 Include a 'wild'  filename and location in document Office 2021
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,453
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

{ FileName \p }
FileName field

Note that the field must be updated after the file is saved in a new location.
Dealing with Fields in Microsoft Word
Reply With Quote
  #3  
Old 09-16-2024, 03:52 PM
jparnold jparnold is offline Include a 'wild'  filename and location in document Windows 10 Include a 'wild'  filename and location in document Office 2010 32bit
Advanced Beginner
Include a 'wild'  filename and location in document
 
Join Date: Jan 2012
Location: Blue Mountains, NSW, Australia
Posts: 41
jparnold is on a distinguished road
Default

Thanks Charles.
Great.
What do you mean by "Note that the field must be updated after the file is saved in a new location."? Do you mean that I need to re-enter the field and before or after I save to the new location?

Also I inserted a header and entered Document: { FILENAME \p } into the header but it did not 'translate' it when I printed even after doing a save (ie just printed that 'code').

Thanks

Last edited by jparnold; 09-16-2024 at 04:00 PM. Reason: add last sentence
Reply With Quote
  #4  
Old 09-16-2024, 04:42 PM
Charles Kenyon Charles Kenyon is offline Include a 'wild'  filename and location in document Windows 11 Include a 'wild'  filename and location in document Office 2021
Moderator
 
Join Date: Mar 2012
Location: Sun Prairie, Wisconsin
Posts: 9,453
Charles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant futureCharles Kenyon has a brilliant future
Default

You cannot simply type this. You have to create the field. Read the link on dealing with fields.
Reply With Quote
  #5  
Old 09-16-2024, 05:21 PM
jparnold jparnold is offline Include a 'wild'  filename and location in document Windows 10 Include a 'wild'  filename and location in document Office 2010 32bit
Advanced Beginner
Include a 'wild'  filename and location in document
 
Join Date: Jan 2012
Location: Blue Mountains, NSW, Australia
Posts: 41
jparnold is on a distinguished road
Default

Thanks I did read the article but probably didn't read it properly/fully.
Thanks again.
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
VBA to save word document as pdf to default location with inputbox to “save as” with filename sugge richardgo Word VBA 0 11-18-2020 09:36 AM
filename field not displaying correct filename when that name starts with # plrsmith Word 1 07-06-2018 03:10 AM
Default location for the Office Document Cache Server drafts location. dianahbr Office 0 03-02-2018 12:37 PM
Include a 'wild'  filename and location in document Save as PDF in specific location with filename using todays date miyoung Word VBA 2 08-15-2017 09:15 AM
Include a 'wild'  filename and location in document Filename after splitting document Julian Word VBA 5 12-08-2015 04:51 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 04:39 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft