RemoveTabStop Method

Removes a tab stop with the specified index from the tab stop collection of the text block, and returns the number of remaining tab stops.

Applies to: TextBlock object

Syntax

[[Let] countRet = ] object.RemoveTabStop ( index )

The RemoveTabStop method syntax has these parts:

Part Description
object Required. An expression that returns a TextBlock object.
index Required. An expression that returns a Long value. The index of the tab stop to be deleted.
countRet Optional. A Long type variable

Remarks

If index is less than 1 or greater than the number of tab stops in the text block, the RemoveTabStop method doesn't delete anything and returns the current number of tab stops in the text block. To find out the number of tab stops in the text block, use the TabSopsNum method.

Example

This example contains a document-level script. It demonstrates how to delete a tab stop with number 1 in a shape. It assumes that the active page contains the shape with ID 1, which has text and at least one tab stop is defined.

Dim s as Shape
s = thisDoc.ActivePage.ShapeByID(1)
' Delete TabStop with ID1, display the number of remaining tab stops trace s.TextBlock.RemoveTabStop(1)

 

See Also

AddTabStop method, TabStop method, TabStopsNum method