Mrrrr's Forum (VIEW ONLY)
Un forum care ofera solutii pentru unele probleme legate in general de PC. Pe langa solutii, aici puteti gasi si alte lucruri interesante // A forum that offers solutions to some PC related issues. Besides these, here you can find more interesting stuff.
Lista Forumurilor Pe Tematici
Mrrrr's Forum (VIEW ONLY) | Reguli | Inregistrare | Login

POZE MRRRR'S FORUM (VIEW ONLY)

Nu sunteti logat.
Nou pe simpatie:
surender_lady pe Simpatie
Femeie
25 ani
Arad
cauta Barbat
26 - 47 ani
Mrrrr's Forum (VIEW ONLY) / Tutoriale si Ghiduri Utile // Tutorials and useful guides / [WORD] Open Document and Collapse All Headings Moderat de TRaP, TonyTzu
Autor
Mesaj Pagini: 1
TRaP
Moderator

Inregistrat: acum 6 ani
Postari: 787
See post #3 for Non-VBA solution

In Word if you create headings (eg. select paragraph / subtitle and click on the style Heading 2 for example) and collapse (close) them all, then save your document and close it, when you open the document again all the headings will be expanded (open) again. You normally cannot open a document with all headings collapsed (closed).

In order to make it happen, you have 2 options:

1. Saving document as macro-enabled (docm) file

Open VBA and under ThisDocument paste the following code:


Private Sub Document_Open()
    ActiveDocument.ActiveWindow.View.CollapseAllHeadings
End Sub

2. Keeping document as normal (doc/docx) file

Note: the headings won't be collapsed on open, but you can collapse and expand them all whenever you want

Paste the following code into a module, then create 2 buttons in your QAT or ribbon for each of the following 2 macros:


Sub Headings_Expand()
    ActiveDocument.ActiveWindow.View.ExpandAllHeadings
End Sub

Sub Headings_Collapse()
    ActiveDocument.ActiveWindow.View.CollapseAllHeadings
End Sub


pus acum 1 an
   
TRaP
Moderator

Inregistrat: acum 6 ani
Postari: 787
Edited to replace "dotm" with "docm".

Dotm is a template file.
Docm is a macro-enabled file.


pus acum 1 an
   
TRaP
Moderator

Inregistrat: acum 6 ani
Postari: 787
To set certain headings to be collapsed by default when you open a specific document, do this:

1. Click on the heading row

2. In the Home tab click on Paragraph arrow (or right click the heading and select Paragraph)

3. In the General section of Indents and Spacing tab (open by default), next to Outline level put a check on "Collapsed by default"

4. You can do this for multiple / all headings, just first collapse all of them, then select them all and do the above.


pus acum 8 luni
   
Pagini: 1  

Mergi la