How to make writer to auto increment an entry like annexes

I’m using version 7.0.2.2 and I could not find a way to creat that auto increments. I am only finding ways to create numbem paragraphs either through lists or Index entry paragraphs, but I want to add information in line with the text like in the following example: " In Annex 1 it is possible to see the primary maintenance record while in Annex 2 the roster with the stamp of the technician signing the first document is available".

2021.02.08 (Additional information to my question)
Adding to my question to make it clearer, the autonumbering is to do the same we do with autonumbering illustrations and tables: if we add, delete or reorder them, the editor changes the numbers accordingly. This is very instrumental if we use references. If I am referencing Annex 4, adding another annex before it make it to be Annex 5 now so does its call elsewhere in the text. Again, this is exactly the same for tables and illustrations. But there are two differences among annexes and table/illustrations. First: I don’t attach an annex in the document. I send my main document in a file and their annexes in individual files. So, in the boddy of the document, I will only mention their names. Example: “see in the annex 1 to this report the manual for component xyz…”.

Second: Tables and Illustrations are paragraphs. The references to annexes are in line with the text. Then, I need to use an autonumbered refereceable entity that is “Text Body” style.

Hope I was clearer. If it is still difficult to sort out, for those who have access to Microsoft Word too, this feature is relatively simple to implement.

A piece of information that might be useful for you smart guys to help me the dumb one is that I don’t need an Automated Annex Summary. It might be a nice thing but in 8 years doing my business I never missed it.

2021.02.09
@ajlittoz’s You’re right. I meant captions.
@lupp What I meant is that captions are paragraph styles for which WRITER handles the numbering. On the textfield functionality, could you explain it in simpler words? I’m a begginer.
@anon87010807 Appendices are some matter exterior to you document that you embed in it. Annexes are exterior matter. In my case, exterior files. Some of them I can’t even manipulate as they are protected. But you’re right that, trhoughout the text, references to appendixes will work the same as my references to my annexes. The only difference is that the annexes will not be within my file.

2021.02.10
@lupp Managed it through your example file. THANKS.

Thanks

Sounds dangerous. Presumably, Annex 1 is a passage of text somewhere else (unless it is an attached building). What happens if one passage is deleted because it is no longer relevant? The numbers would not match the description any more as they would be out of step.

What is the question exactly? Creating numbered annexes the same you create numbered chapters, i.e. restarting the numbering and entering the annexes in the TOC? Or a way to reference some notable paragraph in a reliable form?

Edit your question to improve it. Don’t use “Add answer”. On this site answers are reserved for solutions.

The term “annex” isn’t in any way defined concerning text documents. What you (@lgermani ) explained -and I didn’t clearly understand- about the incrementing of numbers and their automatic adaption to rearrangements of the text leads me to the mental association of “capture” which basically is a group of TextField objects of type Number range with a common TextFieldMaster.Thus: Can you accept a series of TextField objects of this kind for numbering your “annexes” (whatever they are)?
If so, I will can supply an example of how to use this TextField type (or somebody else may do).

Second: Tables and Illustrations are paragraphs.

How so?
Tables are handled partly like paragraphs (by the API). Illustrations are graphics hosted by shapes which in turn are anchored in one or another way inside the document. In case of images inserted into a Writer document as illustrations they are frame-hosted.

Second: Tables and Illustrations are paragraphs.

@Lupp: OP @lgermani probably means captions (which can be auto-numbered) are paragraphs and therefore the number can “easily” be cross-referenced.

I was thinking about Appendices. You can number them, and insert cross-references to the number, so that if you decide to drop an Appendix, the references in the text will stay in sync.

…probably means captions…

I also meant captions, but wrote “captures”. Too bad.
To understand all the rest clearly my Writer experience may be insufficient.

Quote from OP: “First: I don’t attach an annex in the document.” If it’s a separate document, it’s not a caption, not really an appendix either, but closer to an appendix. I wonder how, if all annexes are in separate documents, you can sensibly number them.

Quoting the OQ: “Adding to my question to make it clearer, the autonumbering is to do the same we do with autonumbering illustrations and tables: if we add, delete or reorder them, the editor changes the numbers accordingly.”
I thoroughly read the edited question again, and still suppose the OQ wanted exactly this behaviour, but assumed the >Insert>Caption functionality was only availabele for tables and graphics.
This is wrong. The central functionality of captions is using TextField objects of the Number range type which are easily created independent of the caption tool.
The additional functionality of >Insert>Caption is a specialized and diversified variant of AutoText making the details depend of the kind of thing needing a caption added.
What the OQ looks for (imo) is easily implemented by a custom AutoText entry.
Hope @lgermani will tell if I’m right. An example document is available. (AutoText, of course, must be completed locally.)

Considering the lack of precision in OQ, I read the reference to Annex number as a reference to a chapter number. Annex numbering can be done with Heading n and the number is available through “classic” cross-reference. The difficulty is annexes are independent non-included files. To get the functionality of auto number update when annexes are reordered needs to bind everything with a master document so that Writer has information about order and can do the job.

I’m afraid that OQ has not the competence to build the required inter-document structure. Cross document references are not possible outside master documents.

Hi, I can’t use heading because I need to keep the paragraph as Text Body. Do not worry in handling the annex files; if in a document version one annex is numbered as 3 and later updated to 4, when I am uploading my report in the file system I work with I need to inform that file is the annex 4.
So, the dynamics of the document edition I do is do references to external documents, the annexes, which I number so I can cross-reference them within the document itself using their numbers instead of their names. Example: “this component should be maintained in accordance with the instructiions of its maintenance manual, annex 6 to this report”. If in this example, after further edition the annex ends up as 7, there is no problem. I only need consistency within the document itself. When edition is finished, I rename the files accordingly only to help me with the organization. At the file system, I need to give a name to the file again.

@lgermani: Please Accept the correct answer, you just closed the topic, without accepting an answer. You only use Close, the right answer was accepted by when you aren’t the person who asked the question but found an answer was correct. Then you accept that answer (tick the checkmark) and close the topic (that tells everybody that the answer was not accepted by the person who asked the question). In your case, you are that person, so you accept the answer that worked for you, then you don’t have to close the topic.

I need to keep the paragraph as Text Body

There is no reason for it. If you refuse to use the semantic markup offered by the style system to distinguish the different “value” or meaning or paragraphs, you’ll never succeed in formatting or else at a high manual and error-prone cost.

The best way to inform about annex number change is to let Writer do the job with chapter numbering (and not numbered lists!). You can store your annexes as separate files but you need a master document so that Writer knows which “gatherings” form the book.

You should adapt your workflow to the tool. Remember: every tool implies a change of habit for optimal use. Do you drive screws with a hammer, even if you always worked with hammer and nails?

You must use styles.

Chapter and annex headings should be styled Heading n with numbering enabled in Tools>Chapter Numbering.

For your own sanity, never mix chapter numbering and numbered lists. They are two different things. If you make the Heading n into numbered items with the toolbar button or F12, you’ll create such a mess that your document will no longer be manageable.

Use Heading n to mark up your document outline and numbered lists like Numbering 1 for numbered items.

The chapter/annex number can be inserted with Insert>Cross-reference, Cross-references tab, Type Headings and you click on the “destination”. You’ll get Page, Chapter number or full heading with /Reference* depending on your choice.

This works for “destinations” inside the current document. In your present case, you have the main document and the annexes as separate files. To be able to cross-reference across these files, you need to bind them through a master document where you’ll indicate which files are part of the global book and in which order.

If your documents are all properly styled and consistently styled, you’ll be able to reorder the annexes with simple drag and drop and the numbers will be automatically updated.

I insist on a consistent usage of styles. Failing that, you won’t succeed.

Read the Writer Guide about styles and master documents.

EDIT 2021-02-10 after question 2021.02.09 update

You need a master document to act as a “binder” for the various files. This has for effect to import all bookmarks, captions, numbered headings, etc. into the master document and make them available for references.

Caution! This seems tricky and difficult on the first time and exposes all approximations in styling. As already mentioned, this requires strict and consistent styling. Any direct formatting in the “imported” document will lead to failure.

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.

Quoting @lgermani : “What I meant is that captions are paragraph styles…”
This isn’t correct. Captions are best considered a special kind of AutoText. Calling >Insert>Caption does two or three things:
-1- it inserts a TextField of type Number range and chooses one of the standard “Categories” for it depending of the kind of object it was called for. This TextField does the numbering.
-2- It puts a piece of text in front of or behind that TextField. This text depends on the “Category” again but can be edited without changing the numbering. A predefined paragraph style will be applied, but we have still ordinary text, and you can change the style if you want without afflicting the numbering.
-3- If the object getting the caption not is a table this object and the new caption are enclosed together by a new TextFrame.

The menu item >Insert>Caption is greyed out if not the selection identifies a table or a graphical object for it. Nonetheless you can insert the central element, the TextField explicitly. You can also automate the process with the help of the AutoText tool. See attachment.
Not included with the attachment: If you want to automatically apply a special style to a newly inserted pseudo-caption of the described kind, you will need a “macro”, imo.
ask291451additionalCaptions_0.odt

I got it right as per your instructions, but only because I got the example file. THANKS.