Create TOC on the fly

LibreOffice Writer 6.4

Is it feasible or possible to to create a Table of Contents and update it on the fly? What I mean by “on the fly” is continue writing and build the TOC as I go. Please read my entire post before answering because that will allow you to understand why I want to do this.

This question should be pretty generic, not requiring system specs etc. I am a rank beginner in creating anything but very simple word/text documents. I wish to create a document with a Table of Contents. All the research I have performed leaves me with the impression that the TOC needs to be built in an existing document.

My intended use for the document is to build a tutorial for my own use. I have discovered that I will be required to use headers, styles, etc. I have never done this; therefore, I need to toggle back and forth among various resources for the instructions. I want to create a step wise instruction set to use for the creation of TOCs in the future.

This should prove to be a good learning tool for me.

Thanks in advance for your replies.

regards,

dirty_fingernails

Quickstart:

  • Insert the basic ToC field in the beginning of your document. When you have a “flat text” document, only the ToC title will display.
  • To make content start on a new page, press ctrl+enter
  • As you type, or modify an existing document, press ctrl+1 to specify the current paragraph as a main heading (like a chapter title).
  • To rebuild the ToC from newly defined headings, right click the ToC title and find the update item in the context menu.

You can use ctrl+number (2, 3, 4) for multiple levels of subheading.

If you don’t like the appearance of your headings, don’t format directly. Rather, adjust the Heading 1 paragraph style to suit your taste.

good quick start

To make it short while waiting you finish reading the Writer Guide, styles are used to mark up paragraphs or other elements/objects to confer them attributes or roles.

The outline of your document (its chapter structure) must be marked up with the family of Heading n (n = 1 to 10) paragraph styles.

A paragraph which is a heading for a chapter is style with Heading 1, a sub-chapter with Heading 2, etc. To do that, put the cursor in the heading and use the paragraph style drop-down menu of the toolbar to select the appropriate style. Unless you customised your toolbar, it is the leftmost menu.

Note that your heading will not be numberd until you activate Tools>Chapter Numbering.

A TOC is inserted at the position of the cursor with Insert>Table of Contents & Index>Table of Contents, Index or Bibliography. Everything marked up with Heading n will be collected and formatted.

A TOC does not follow in real-time the evolution of your document. You must refresh it manually. You do that either with Tools>Update>Update All or right-clicking in the TOC and Update Index.

There are many more. Play first with simple thing and discover progressively the power features.

To show the community your question has been answered, click the ✓ next to the correct answer, and “upvote” by clicking on the ^ arrow of any helpful answers. These are the mechanisms for communicating the quality of the Q&A on this site. Thanks!

In case you need clarification, edit your question (not an answer which is reserved for solutions) or comment the relevant answer.

Thanks for the step wise guide for me to get started. The explanations with paths to access various settings will be very useful to me. Your style is that of a teacher, which is a very good thing.

The instructions for using this forum are a bonus!

regards,

dirty_fingernails

I’ve never been a teacher :wink: Maybe I should consider that.

At least consider writing stand alone tutorials. (I am not a teacher by profession. However, I started tutoring when I was in the fifth grade [in 1962]. I have been tutoring ever since.)

I’m considering writing a book of tips and tricks about Writer to complement the official guide. But, first, I’d like to finish with what I’m currently doing.

That sounds good. It would be a laborious task with great rewards. Best of luck to you.

I have discovered that I will be
required to use headers, styles, etc.
I have never done this;

Yes, you must use these features if you want to create a TOC by some clicks and you want to refresh it automatically. …And you must have a proper structure in your documents: the Heading styles must be assigned to the Chapter numbering structure of the document.

There are excellen descriptions - for usage of the Writer application - if the Help does not help you.