Cells.Split Method (Word)
Splits a range of table cells.
Syntax
expression .Split(NumRows, NumColumns, MergeBeforeSplit)
expression Required. A variable that represents a Cells collection.
Parameters
Name |
Required/Optional |
Data Type |
Description |
---|---|---|---|
NumRows |
Optional |
Variant |
The number of rows that the cell or group of cells is to be split into. |
NumColumns |
Optional |
Variant |
The number of columns that the cell or group of cells is to be split into. |
MergeBeforeSplit |
Optional |
Variant |
True to merge the cells with one another before splitting them. |
Example
This example merges the selected cells into a single cell and then splits the cell into three cells in the same row.
If Selection.Information(wdWithInTable) = True Then
Selection.Cells.Split NumRows:=1, NumColumns:=3, _
MergeBeforeSplit:= True
End If