Referenced Documents

G

GoCraig

I have a set of manuals to write for a Client for a single Project. The
variouis manuals range in page numbers from 20-30 up to multiple hundreds so
we did not want to write as a single document or even combine them at a later
date.

We are using Referenced Document (RD) functionality, so have built 21
seperate chapters, of which the 1st chapter is a Contents Index document.
This chapter contains the RD references and the result is a consolidated
Contents section and a Consolidated Index section, making reference and
access easy.

Each document has a custom field/property called Status and we use this to
control the status (draft/final) and the version number (1.1) as a combined
text string (final 1.1).

Within Chapter 1, under its own Version Control section, it would be really
useful if we could include a table that listed the various documents and
their Status.

Is thsi possible ?????
 
M

macropod

Hi GoCraig,

You can, but the process is a bit complicated:

1. In each source document, insert a DOCPROPERTY field, coded as {DOCPROPERTY Status}. Then press F9. This shows the document's
status on the document itself.

2. If you attach this field to a suitable heading that's referenced by your target document, then that's all you'll need to do. The
status will show up in the target document's TOC entries for the same headings.

3. If (2) doesn't suit your needs, you'll need to locate the DOCPROPERTY field in relatively safe location (eg the header) and embed
it in a SET field, coded {SET Status DOCPROPERTY Status}}. Then press F9. This bookmarks and hides the DOCPROPERTY field.

4. In your target document, insert an INCLUDETEXT field (coded the same as the RD field you're already using) and add "Status" to
it. This will pull across the source document's status. You can place this field immediately after the corresponding RD field.
 
G

GoCraig

Thanks macropod that all makes sense.

I already have a DOCPROPERTY field on the source documents as that is used
to display the Version on the front page of each chapter so I didnt need to
add that.

My Source Document and my target document are in the directory.

Using the Insert Field option on the menus, I have tried the following

{ INCLUDETEXT "02 - Sample - Document.doc" Status \* MERGEFORMAT }
{ INCLUDETEXT "./02 - Sample - Document.doc" Status \* MERGEFORMAT }
{ INCLUDETEXT ".//02 - Sample - Document.doc" Status \* MERGEFORMAT }

And then the same again with the %20 instead of spaces
{ INCLUDETEXT "02%20-%20Sample%20-%20Document.doc" Status \* MERGEFORMAT }

But each time I get
Error! Not a valid filename.

I have also tried Bookmarking the DOCPROPERTY in the Source and referencing
that in the INCLUDETEXT instead, but it still returns the same message.

What am I doing wrong ???
 
M

macropod

Hi GoCraig,

Your INCLUDETEXT field needs the full path and filename and the bookmark name should be in quotes - something along the lines of:
{INCLUDETEXT "C:\\My Documents\\User Manual\\02 - Sample - Document.doc" "Status"}
I assume you've already got the RD fields working, so see those for the required name & path string. You can see the lot via Alt-F9.
 
G

GoCraig

Havent had a chance to have a go with this until now, sorry for the lack of
feedback.

I thought that I had go it working, but it was just kidding me.

My RD Fields are working just fine in that they are relative paths so they
only contain the fiel name and I include a /f to indicate that they are
relative.

This doesnt seem to work with INCLUDETEXT, so as per your instruction I
added in full path information, I ended up with something like ...

{ INCLUDETEXT "H:\\Projects\\Test\\50 - Documentation\\02 - Sample -
Business Overview.doc" "Version" \* MERGEFORMAT }

Which returned ..... Error! Not a valid filename.

This is where it then got strange again

Whilst viewing the code bit, if I right click and choose update field it
changes to what looks like a version number, however this is not from the
referenced document but from the current one.

When I toggle field codes my code has changed to the following ...

{ DOCPROPERTY Status \& MERGEFORMAT }

This explains why I get a version number back, but I dont know why word is
changing what I have asked it to do.

Sorry, I am sure I am doing something stupid, but I cant get my head around
it. Am gonna keep trying, so will update this again later if I figure it out,

Any further suggestions would be appreciated
 
G

GoCraig

Through a little playing around I think I have figured out what the problem is.

In a file called Doc2.doc, I have added a Custom Property Field called
Version and entered 1.1.5.7 as the value. Within the Document I have
Inserted a Field that pulls this value from the Properties and displays is.
This is achieved using the following ...

{ DOCPROPERTY Version \* MERGEFORMAT }

I have then bookmarked this content and called the Bookmark Fred

On a different line of Doc2, I have typed 1.1.5.7 straight onto the Page and
bookmarked it, calling the Bookmark George

In Doc1.doc I have added two INCLUDETEXT fields

{ INCLUDETEXT "c:\\\\Doc2.doc" "Fred" \MERGEFORMAT }

{ INCLUDETEXT "c:\\\\Doc2.doc" "George" \MERGEFORMAT }

George works fine, Fred doesnt

What Fred actually does is pull in the Code so you end up with

{ DOCPROPERTY Version \* MERGEFORMAT }

in Doc1, which in turn fails as the value Version does not exist there

Thanks again for your help macropod, hopefully this chain will be of use to
someone else struggling wioth anything similar !!!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top