Share via

Can one reference another document's properties?

Anonymous
2012-04-10T09:33:03+00:00

I am splitting a longer document into several pieces.

Consequently there will be a couple of references between the individual parts. Since things are still in high flux, most likely even the names fo the individual parts will change, so I would keep the references "dynamic". Can one reference and insert another document's properties (like title or subject) into the current document?

Michael

Microsoft 365 and Office | Word | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2012-04-27T19:18:20+00:00

FWIW I think we covered most of the ground on the INCLUDETEXT front. 

AFAICS you can however include the same text using the LINK field mechanism, in which case document property values in (e.g.) content controls in the linked text are the ones from the included file.

However, there is a really significant problem doing that, which you may already know, which is that Word destroys any field codes nested inside a LINK field when you either save or re-open the file containing the link. So you still have the problem that you have been discussing in your other conversations with trying to find a mechanism for modifying the links when the file locations change. In the other cases, you can probably get the user to select all the text of the container file and press F9. In this case you'd almost certainly need a bit of VBA code to go through an fix up the links. Macropod has some code for that, but I don't have the relevant link to hand.

That said, the field code for a LINK field is similar to the field code for an INCLUDETEXT field, except that the LINK field also specifies a link type. So you have something like

{ LINK Word.Document.12 "c:\xyz\included.docx" bookmark \a \t }

where "bookmark" is the bookmarked area to include.

As I said, nested fields in LINK fields won't survie a LINK field update. Further, no other mechanism I have tried other than VBA works around it. For example, if you replace the path and bookmark name by content controls that contain the path and bookmark name, and mark the content controls so that they "cannot be deleted", Word leaves the controls there but you end up with a field soomething like this:

{ LINK Word.Document.12 "c:\xyz\included.docx" bookmark Word.Document.12 "c:\xyz\included.docx" bookmark \a \t }

where everything up to the second "c:\ is plain text.

That's not to say that there isn't a way, but if there is, I have never seen it.

Was this answer helpful?

0 comments No comments

3 additional answers

Sort by: Most helpful
  1. Anonymous
    2012-04-11T09:34:20+00:00

    I know that thread! It's my other thread dealing with what I think is a bug in Word 2010, namely that properties in referenced bookmarks are replaced using the wrong context.

    In this thread I am asking, whether one can access another file's properties, like Title, Author, Status, etc.

    M.

    Was this answer helpful?

    0 comments No comments
  2. Paul Edstein 82,861 Reputation points Volunteer Moderator
    2012-04-11T04:18:24+00:00

    Was this answer helpful?

    0 comments No comments