SpaceBetweenColumns Property

Microsoft Word Visual Basic

SpaceBetweenColumns Property

       

Returns or sets the distance (in points) between text in adjacent columns of the specified row or rows. Read/write Single.

expression.SpaceBetweenColumns

expression   Required. An expression that returns one of the objects in the Applies To list.

Example

This example creates a 3x3 table in a new document and then sets the distance between columns in the first row to 0.5 inches.

Set newDoc = Documents.Add
Set myTable = newDoc.Tables.Add(Selection.Range, 3, 3)
myTable.Rows(1).SpaceBetweenColumns = InchesToPoints(0.5)

This example returns the distance (in points) between columns in the selected table rows.

If Selection.Information(wdWithInTable) = True Then
    MsgBox Selection.Rows.SpaceBetweenColumns
End If