Indexes object (Word)
A collection of Index objects that represents all the indexes in the specified document.
Remarks
Use the Indexes property to return the Indexes collection. The following example formats indexes in the active document with the classic format.
ActiveDocument.Indexes.Format = wdIndexClassic
Use the Add method to create an index and add it to the Indexes collection. The following example creates an index at the end of the active document.
Set myRange = ActiveDocument.Content
myRange.Collapse Direction:=wdCollapseEnd
ActiveDocument.Indexes.Add Range:=myRange, Type:=wdIndexRunin
Use Indexes (Index), where Index is the index number, to return a single Index object. The index number represents the position of the Index object in the document. The following example updates the first index in the active document.
If ActiveDocument.Indexes.Count >= 1 Then
ActiveDocument.Indexes(1).Update
End If
See also
Support and feedback
Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.
Saran dan Komentar
https://aka.ms/ContentUserFeedback.
Segera hadir: Sepanjang tahun 2024 kami akan menghentikan penggunaan GitHub Issues sebagai mekanisme umpan balik untuk konten dan menggantinya dengan sistem umpan balik baru. Untuk mengetahui informasi selengkapnya, lihat:Kirim dan lihat umpan balik untuk