Skip to content

Latest commit

 

History

History
61 lines (41 loc) · 1.38 KB

Word.Rows.NestingLevel.md

File metadata and controls

61 lines (41 loc) · 1.38 KB
title keywords f1_keywords api_name ms.assetid ms.date ms.localizationpriority
Rows.NestingLevel property (Word)
vbawd10.chm155975783
vbawd10.chm155975783
Word.Rows.NestingLevel
54a34d92-08bc-fb66-3a29-5e491d370307
06/08/2017
medium

Rows.NestingLevel property (Word)

Returns the nesting level of the specified table rows. Read-only Long.

Syntax

expression. NestingLevel

expression Required. A variable that represents a Rows object.

Remarks

The outermost table has a nesting level of 1. The nesting level of each successively nested table is one higher than the previous table.

Example

This example creates a new document, creates a nested table with three levels, and then fills the first cell of each table with its nesting level.

Documents.Add 
ActiveDocument.Tables.Add Selection.Range, _ 
 3, 3, wdWord9TableBehavior, wdAutoFitContent 
With ActiveDocument.Tables(1).Range 
 .Copy 
 .Cells(1).Range.Text = .Cells(1).NestingLevel 
 .Cells(5).Range.PasteAsNestedTable 
 With .Cells(5).Tables(1).Range 
 .Cells(1).Range.Text = .Cells(1).NestingLevel 
 .Cells(5).Range.PasteAsNestedTable 
 With .Cells(5).Tables(1).Range 
 .Cells(1).Range.Text = _ 
 .Cells(1).NestingLevel 
 End With 
 End With 
End With

See also

Rows Collection Object

[!includeSupport and feedback]