Object Model Reference : Classes : T : TextRange : Methods : TextRange.Range |
Function Range(Start As Long, End As Long) As TextRange
Member of TextRange
The Range method returns a range of characters from a text range.
Parameter
|
Description
|
Start
|
Specifies the first character in the range
|
End
|
Specifies the last character in the range
|
The following VBA example applies bold formatting to the fourth to seventh characters in the range.
Sub Test() |
Dim d As Document |
Dim s As Shape |
Dim t As Text |
Set d = CreateDocument |
Set s = d.ActiveLayer.CreateParagraphText(3, 3, 5, 5, _ |
"This is an example.") |
Set t = s.Text |
t.Story.Range(4, 7).Bold = True |
End Sub |
Copyright 2013 Corel Corporation. All rights reserved.