Share via

STYLEREF Bible Chapter and Verses

Anonymous
2023-08-26T11:14:13+00:00

I am editing a Bible, and in the header, I have STYLEREFs with the chapter and verse. The chapter and verse are populated based on a Style that I made for each one. This works fine except in the cases when a new chapter starts on a page with text that is in another chapter. So, instead of having 1:43–2:4 for example, it will show 2:43–2:4.

In that case, the STYLEREF does not recognize the first chapter since it started on an earlier page, and it only shows the chapter on the current page.

Along these lines, I would also like for the STYLEREF to show 1:20-35 for example, if there is not a new chapter introduced on the page. At the moment, it has 1:20–1:35.

Is there a way to use conditional logic to solve these issues? Or is there another solution to these problems?

Thanks for any feedback.

Microsoft 365 and Office | Word | For education | MacOS

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

2 answers

Sort by: Most helpful
  1. Anonymous
    2023-08-26T18:45:26+00:00

    Thank you for your reply. I think there is some misunderstanding. I have two separate Styles: 1. Chapter; 2. Verse.

    As it stands, I am able to generate those correctly. However, in certain parts of the document, a new chapter begins on a page with text from the previous chapter. In those cases, it correctly identifies the last verse of the page, but it puts the incorrect chapter for the start of the page since it reads the second chapter as the only chapter occurring on the page.

    I am currently using the following STYLEREF:

    {STYLEREF "Chapter"}:{STYLEREF "Verse"}– {STYLEREF "Chapter"}{STYLEREF "Verse"}.
    

    I would like to distinguish cases where a new chapter begins on a page. Thus, when I have a page that begins with 1:43 and ends with 2:4, I would like the header to show 1:43–2:4.

    In the second example, when the page begins with 1:25 and ends with 1:42, I would like for it to say 1:25–42.

    The document I am working with has 28 chapters, if that helps. Each chapter has a different number of verses, and sometimes a chapter begins on a new page, and sometimes it begins on a page with a previous chapter. I hope this clarifies.

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2023-08-26T16:34:54+00:00

    Hi, thanks for your question. It sounds like you are working on a complex project and you need some help with the STYLEREF fields in Word. Here are some possible troubleshooting steps you can try:

    • Make sure you have applied the correct style to the chapter and verse numbers in your document. You can use the Reveal Formatting pane (Shift + F1) to check the style of any text.
    • If you have multiple STYLEREF fields on the same page, you may need to use the \l switch to specify the level of the style you want to reference. For example, if your chapter style is Heading 1 and your verse style is Heading 2, you can use { STYLEREF 1 \l 1 } for the chapter number and { STYLEREF 1 \l 2 } for the verse number.
    • To avoid repeating the chapter number when it is the same as the previous page, you can use the \n switch to suppress it. For example, if you have { STYLEREF 1 \l 1 }-{ STYLEREF 1 \l 2 } on the first page and { STYLEREF 1 \l 1 \n }-{ STYLEREF 1 \l 2 } on the second page, it will show 1:20–35 instead of 1:20–1:35.
    • To avoid showing the wrong chapter number when a new chapter starts on a page with text from another chapter, you can use a bookmark to mark the start of the new chapter and then use a REF field to reference it. For example, if you insert a bookmark named Chapter2 at the beginning of chapter 2, you can use { REF Chapter2 }-{ STYLEREF 1 \l 2 } instead of { STYLEREF 1 \l 1 }-{ STYLEREF 1 \l 2 }.

    I hope this helps. Please let me know if you have any further questions or issues.

    Was this answer helpful?

    0 comments No comments