[Solved] Skip unnumbered pages for Page N of NN
-
- Posts: 6
- Joined: Wed Feb 12, 2025 7:30 am
[Solved] Skip unnumbered pages for Page N of NN
Having documents with a title page (unnumbered) followed by text pages and the demand to show <page> of <pages> in the footer. However, the "statistics" field seems to always uses the page count from the whole document. Is there a way to display only the number of numbered pages. In my example, if the doc has 26 pages, the footer on page 2 should be "page 1 of 25"? Couldn't find anything about this - but I am new to OO and may have missed something...
Last edited by MrProgrammer on Sat Feb 22, 2025 1:03 am, edited 1 time in total.
Reason: Tagged ✓ [Solved] Multiple solutions provided
Reason: Tagged ✓ [Solved] Multiple solutions provided
OpenOffice 4.1.15 on Windows 11
Re: Achieving something like "section pages" in MS Word
So you want to start page numbering from something other than the first page?
See [Tutorial] Page numbering. Especially the sections Showing, hiding or restarting the page number and Total pages number by chapter or section.
See [Tutorial] Page numbering. Especially the sections Showing, hiding or restarting the page number and Total pages number by chapter or section.
Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 25.2.31.2; SlackBuild for 25.2.3 by Eric Hameleers
---------------------
Apache OpenOffice 4.1.15
LibreOffice 25.2.31.2; SlackBuild for 25.2.3 by Eric Hameleers
---------------------
Roses are Red, Violets are Blue]
Unexpected '{' on line 32
.- MrProgrammer
- Moderator
- Posts: 5258
- Joined: Fri Jun 04, 2010 7:57 pm
- Location: Wisconsin, USA
Re: Achieving something like "section pages" in MS Word
attach a Writer document demonstrating the difficulty (remove confidential information then use Post Reply, not Quick Reply, and don't attach a picture instead of the document itself). I will not help further unless you attach.
If this solved your problem please go to your first post use the Edit ✏️ button and add [Solved] to the start of the Subject field. Select the green checkmark icon at the same time.
I seldom use Writer so it's possible that this simple idea may not be appropriate for your situation. If you need any additional assistance If this solved your problem please go to your first post use the Edit ✏️ button and add [Solved] to the start of the Subject field. Select the green checkmark icon at the same time.
Mr. Programmer
AOO 4.1.7 Build 9800, MacOS 13.7.5, iMac Intel. The locale for any menus or Calc formulas in my posts is English (USA).
AOO 4.1.7 Build 9800, MacOS 13.7.5, iMac Intel. The locale for any menus or Calc formulas in my posts is English (USA).
-
- Posts: 6
- Joined: Wed Feb 12, 2025 7:30 am
Re: Achieving something like "section pages" in MS Word
Thank you, Mr. Programmer. It works, in a way... my use case is I have to deal with programmatically generated DOCX files that "are as they are provided" and change these "page" and "sectionpages" fields to something useful in OO.
If I try to delete the "sectionpages" field OO tells me about read-only content that's not removable, showing field names displays - nothing. I have to delete the whole "page n of m" part to get rid of the r/o invisible...
Adding the setpage variable and pointing to it in the footer works, but the page number itself doesn't adapt, and so it shows "2 of 1", 3 of 2" and so forth.
These are 50+ page documents with a lot of confidential numbers in it. I tried to set up a sample with 3 or 4 pages, but after doing this the whole footer had gone after re-opening the odt. Will try again and attach it later.
If I try to delete the "sectionpages" field OO tells me about read-only content that's not removable, showing field names displays - nothing. I have to delete the whole "page n of m" part to get rid of the r/o invisible...
Adding the setpage variable and pointing to it in the footer works, but the page number itself doesn't adapt, and so it shows "2 of 1", 3 of 2" and so forth.
These are 50+ page documents with a lot of confidential numbers in it. I tried to set up a sample with 3 or 4 pages, but after doing this the whole footer had gone after re-opening the odt. Will try again and attach it later.
OpenOffice 4.1.15 on Windows 11
- Hagar Delest
- Moderator
- Posts: 33336
- Joined: Sun Oct 07, 2007 9:07 pm
- Location: France
Re: Achieving something like "section pages" in MS Word
There is a trick to anonymize a file in that topic: How to attach a document here.
It may be a vendor lock-in policy due to the use of .docx file format.
But having a look at the file would be best to see if there is an easy fix with AOO or LibreOffice (it may have a better compatibility in this case).
It may be a vendor lock-in policy due to the use of .docx file format.
But having a look at the file would be best to see if there is an easy fix with AOO or LibreOffice (it may have a better compatibility in this case).
LibreOffice 25.2 on Linux Mint Debian Edition (LMDE Faye) and 24.8 portable on Windows 11.
-
- Posts: 6
- Joined: Wed Feb 12, 2025 7:30 am
Re: Achieving something like "section pages" in MS Word
Thank you for providing the trick to anonymize. I attached the odt I got saving the docx (this is too large to attach). Would be very kind if you could take a look.
I attached 3 screenshots:
- Footer (the forum software doesn't attach it. Is there a maximum of attachments?)
- Footer with Field names
- Footer with selected "56" and trying to remove this
I attached 3 screenshots:
- Footer (the forum software doesn't attach it. Is there a maximum of attachments?)
- Footer with Field names
- Footer with selected "56" and trying to remove this
- Attachments
-
- Footer in ODT showing field names.png (3.7 KiB) Viewed 6363 times
-
- Footer in ODT trying to remove the selected 56.png (20.95 KiB) Viewed 6363 times
-
- OO_Problem_Footer.odt
- (81.8 KiB) Downloaded 34 times
OpenOffice 4.1.15 on Windows 11
- Hagar Delest
- Moderator
- Posts: 33336
- Joined: Sun Oct 07, 2007 9:07 pm
- Location: France
Re: Achieving something like "section pages" in MS Word
Well, another case where LO does better than AOO. It imported the footer better it seems since I can modify it directly:
LibreOffice 25.2 on Linux Mint Debian Edition (LMDE Faye) and 24.8 portable on Windows 11.
-
- Posts: 6
- Joined: Wed Feb 12, 2025 7:30 am
Re: Achieving something like "section pages" in MS Word
@Hagar Did you manage to get displayed "page 1 of 56" on the 2nd page?
OpenOffice 4.1.15 on Windows 11
- Hagar Delest
- Moderator
- Posts: 33336
- Joined: Sun Oct 07, 2007 9:07 pm
- Location: France
Re: Achieving something like "section pages" in MS Word
Sure, see attachment. Note the field page number at the end that has been set to a bookmark. You can then hide that text with the character properties set to hidden.
The total number of pages is 58 because of the odd/even page number rule that is explained in the tutorial linked above. Please add [Solved] at the beginning of the title in your first post (top of the topic) with the ✎ button if your issue has been fixed.
The total number of pages is 58 because of the odd/even page number rule that is explained in the tutorial linked above. Please add [Solved] at the beginning of the title in your first post (top of the topic) with the ✎ button if your issue has been fixed.
LibreOffice 25.2 on Linux Mint Debian Edition (LMDE Faye) and 24.8 portable on Windows 11.
-
- Posts: 6
- Joined: Wed Feb 12, 2025 7:30 am
Re: Achieving something like "section pages" in MS Word
I opened the file in LO, AOO refuses to open it, and the footer on page 2 shows "Seite 3 von 58 (total 58). Is it "Seite 1...", when you open it?
OpenOffice 4.1.15 on Windows 11
- Hagar Delest
- Moderator
- Posts: 33336
- Joined: Sun Oct 07, 2007 9:07 pm
- Location: France
Re: Achieving something like "section pages" in MS Word
It is (LO 24.8.2 portable under Windows 10):
Note the blank page and the first page without footer.
Note the blank page and the first page without footer.
LibreOffice 25.2 on Linux Mint Debian Edition (LMDE Faye) and 24.8 portable on Windows 11.
-
- Posts: 6
- Joined: Wed Feb 12, 2025 7:30 am
Re: Achieving something like "section pages" in MS Word
How can I make the blank page visible? How did you make the page 3 counting page 1? Can't find a field code in your document.
OpenOffice 4.1.15 on Windows 11
- Hagar Delest
- Moderator
- Posts: 33336
- Joined: Sun Oct 07, 2007 9:07 pm
- Location: France
Re: Achieving something like "section pages" in MS Word
The blank page is visible in print preview mode or with the Book view left of the zoom slider in the bottom toolbar.
For the field, please check the tutorial linked in the first reply of this topic.
Note that in the document, I used the page number field as the bookmark text. It is easier to follow the tutorial and just put a string that says it is the last page.
For the field, please check the tutorial linked in the first reply of this topic.
Note that in the document, I used the page number field as the bookmark text. It is easier to follow the tutorial and just put a string that says it is the last page.
Edit: I have changed the attachment to make the bookmark more clear (not as a page number field). |
LibreOffice 25.2 on Linux Mint Debian Edition (LMDE Faye) and 24.8 portable on Windows 11.