Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-05-2014, 07:59 AM
bwofficer bwofficer is offline Re-using document title, number, revision number, etc. Windows 7 64bit Re-using document title, number, revision number, etc. Office 2010 64bit
Novice
Re-using document title, number, revision number, etc.
 
Join Date: Dec 2014
Posts: 9
bwofficer is on a distinguished road
Default Re-using document title, number, revision number, etc.

I am getting very confused about the different ways to store document metadata for a Word 2010 document and be able to display it identically in several places within a document and in some cases make it editable from one place within the document whilst updating everywhere else it appears.



I have come across document properties, custom document properties, fields codes, quick parts and content controls and I suspect one of these will let me do what I want, but which? I'm getting rather muddled over which is best for what.

Getting specific, I am trying to create a template for a set of documents which are subject to manual revision control and document numbering. When someone creates a new document in the set, I want them to type in a title and a 2-digit document number (maybe on the title page, maybe in a pop-up box, whichever works best). I then want to automatically generate a full document number consisting of the set number (fixed at 004), the 2-digit document number, and a 2-digit revision number (which initially starts at 00). The full document number and document name will be repeated in the page headers, but as view-only (i.e. I don't want the user to be able to edit the name or number in the headers - I want them to have to edit it where it appears on the title page, then for all the other copies to update themselves automatically).

I've spent a while messing around with field codes, content controls, document properties, etc. and I can't seem to fathom out what will work best. Advice, please?

I can create a custom document property then make it appear in the document as a field code, but then I don't think it's editable within the document at all. I can do Insert > Quick Part > Document Properties and insert things like document author in several places, and it seems like changing one instance will update the rest, but Word 2010 only seems to let you do that for a limited set of document properties and not any custom ones you create. I can insert a content control using the Developer tab, and I get a box I can type in, but then what? Not got a clue how to use that.

So can anyone help me make sense of what all these different things are and which one will let me do what I want?
Reply With Quote
  #2  
Old 12-05-2014, 08:47 AM
gmayor's Avatar
gmayor gmayor is offline Re-using document title, number, revision number, etc. Windows 7 64bit Re-using document title, number, revision number, etc. Office 2010 32bit
Expert
 
Join Date: Aug 2014
Posts: 4,106
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Some time ago, Greg Maxey and I developed an add-in providing simple access to document variables, bookmarks, and document properties, but we had different sets of priorities with where we wanted to take the add-ins, so while he developed his with the emphasis on Content Controls, I removed the Content Controls components and made a more simple tool.

My version is at http://www.gmayor.com/BookmarkandVariableEditor.htm, his you can find linked from that page.

Which brings us back to your question. The add-in will show at a glance what is inserted in the document, and will provide the means of editing values.

I quite like to use Document Variables to store data, and these can be displayed using DocVariable fields. Any field including cross references you use to display data can be unlinked and it then becomes text which you can modify.

You can use this tool to help determine how you want to store the document information you require and then, you can create a VBA userform to store exactly what you want, where you want it, and to generate the numbers that you want to store.

If you decide you prefer content controls, then Greg's web site will tell you far more than you thought you needed about using these controls.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #3  
Old 12-05-2014, 08:53 AM
bwofficer bwofficer is offline Re-using document title, number, revision number, etc. Windows 7 64bit Re-using document title, number, revision number, etc. Office 2010 64bit
Novice
Re-using document title, number, revision number, etc.
 
Join Date: Dec 2014
Posts: 9
bwofficer is on a distinguished road
Default

Thanks, but that's confusing me even more. You introduce another term - DocVariables - but I'm not sure if those are the same as document properties or are different beast altogether. I don't understand from your post or your web page how you get info into these whatevers and how you make use of them.

One thing I think I did grasp is that what you suggest would require an add-on. I can't guarantee that all users of the template would have that.

You also mention creating VBA userforms and I don't know what these are either. It's clear you are pitching your answer at a much greater level of technical knowledge than I actually have!
Reply With Quote
  #4  
Old 12-05-2014, 11:04 PM
gmayor's Avatar
gmayor gmayor is offline Re-using document title, number, revision number, etc. Windows 7 64bit Re-using document title, number, revision number, etc. Office 2010 32bit
Expert
 
Join Date: Aug 2014
Posts: 4,106
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Document Variables are just another way of storing information in a document. They are a bit like custom document properties, which you could equally use. However you would have to write to them (or edit them) using a macro. The add-in I mentioned uses such a macro, so you can see what is possible.

The add-in was merely an aid to establishing which type of data management you want to use as it addresses all of them and allows you to play around with them.

The users wouldn't need the add-in. To do what you require will require a macro that calls a userform to gather the data you require, from the user and writes it to the storage location you choose. That macro would become part of the document template.

I have attached an example template. Create a new document from it. Save the document and close it, then open the document (you will have to allow the macros if you don't put the template in the User Templates folder).
Attached Files
File Type: zip Example.zip (625.2 KB, 6 views)
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote
  #5  
Old 12-11-2014, 05:21 AM
bwofficer bwofficer is offline Re-using document title, number, revision number, etc. Windows 7 64bit Re-using document title, number, revision number, etc. Office 2010 64bit
Novice
Re-using document title, number, revision number, etc.
 
Join Date: Dec 2014
Posts: 9
bwofficer is on a distinguished road
Default

Thanks!

I managed to get something that works, in the end.

I couldn't access the Greg Maxey site as my firm's web blocker decided it was "military content". Turns out he mentions his old US Navy rank and that was enough to upset the filter, which seems to be set on a hair-trigger! By the time our IT chap got that fixed, I'd sussed doing it using content controls using other web resources as guides.

What I've done is create one text content control called DocNumEntry, set to editable, and multiple others call DocNumEcho, set to not editable. Then using the app Word 2007 Content Control Toolkit I enter XML thingies for DocNumEntry and DocNumEcho and link them by dragging from one pane to the other in the toolkit. Whatever that is doing in XML (which might as well be Greek to me) it seems to work - you type a document number in the DocNumEntry content control and it automatically appears in the non-editable DocNumEcho controls too. As long as I stick to the steps laid out in the tutorial example I'm using, it doesn't matter that I don't really understand the nitty-gritty.

(Unless I manage to break it, that is, when I'd be well and truly buggered!)

All of which is a long-winded way of saying I think it's all sorted now.
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to find number of coma and then add that number of rows in word using macro? PRA007 Word VBA 7 05-27-2015 10:45 PM
Re-using document title, number, revision number, etc. How to format a TOC (level 1) using a number, but have the number hidden in the text porpoiseoil Word 1 09-13-2014 12:53 PM
Re-using document title, number, revision number, etc. Heading's Footnote's number is displayed in TOC. How to remove the number in TOC? Orehrepus Word 1 07-13-2014 12:51 PM
Re-using document title, number, revision number, etc. How to create a table with a number of line depending a number entered by user Cellendhyll Word Tables 3 07-10-2014 05:49 AM
Page number with chapter number but not from Heading 1 alpruett Word 5 06-04-2014 02:00 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 06:25 AM.


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