Topic header changes are ignored in DOCX output

Please post all questions and comments regarding Help & Manual 7 here.

Moderators: Alexander Halser, Tim Green

Post Reply
Simon Dismore
Posts: 454
Joined: Thu Nov 16, 2006 1:29 pm
Location: London, UK

Topic header changes are ignored in DOCX output

Unread post by Simon Dismore »

I don't know whether this is a bug or a design decision that should be documented at http://help.ec-software.com/index.html? ... eaders.htm
  1. Start H&M 7.0.0 build 3631
  2. Click the "Examples" link
  3. Click the "Get me started" example project
  4. Navigate to the topic "Publishing your project"
  5. Change the topic heading, e.g. to "Publishing your shiny new project"
  6. Save
  7. Publish to Word (I used the 'Word-Template-Simple-A4' template)
  8. Accept a new folder if you are prompted to
  9. The published document will be loaded into Word automatically
  10. Enable Macros if you are prompted to
  11. Check the TOC (on page 2)
    The topic heading has not been changed. This is as expected, because the TOC wasn't edited.
  12. Check the topic (on page 32)
    Bug?: the topic heading has not been changed
User avatar
Tim Green
Site Admin
Posts: 23155
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Topic header changes are ignored in DOCX output

Unread post by Tim Green »

Hi Simon,

This is normal behavior and intended. The headings in DOCX are taken from the TOC entries, not from the topic header. There is also only one variable for this, unlike PDF, w where you have the HEADING and HEADINGLONG variants to get the text from the TOC or the topic header. This is because it isn't possible to have different text for the topic headings and the TOC entries in DOCX: In Word, the TOC is generated directly from the topic headings, and if the long texts were permitted there then the TOC entries would frequently be too long.
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
Simon Dismore
Posts: 454
Joined: Thu Nov 16, 2006 1:29 pm
Location: London, UK

Re: Topic header changes are ignored in DOCX output

Unread post by Simon Dismore »

Tim Green wrote:In Word, the TOC is generated directly from the topic headings
I can see that's the way H&M 7 currently does it. It would have been possible to generate {TC} fields instead, like this:

Publishing your shiny new project{TC "Publishing your project" \f C \l 1}

If you then build your TOC with {TOC \u \f} you'll get the short text in the TOC and the long text in the topic. The {TC} approach gives more control – e.g. you can have multiple tables of contents – but is less friendly if you are aiming to generate a document that other people can edit downstream in Word. Maybe something to think about for the future.
Post Reply