GetItem Method
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. Core. SDK TXTextControl.from the private NuGet feed or Text Control Offline PackagesCore. dll
- Also in
TXTextControl.asTextControl. ASP. SDK TXTextControl.dll
Description
Gets a particular page from the collection.
Syntax
GetItem()
Gets the Page containing the current text input position from the collection.
public Page GetItem();Public Function GetItem() As PageGetItem(int)
Gets the Page at a certain text input position.
public Page GetItem(int textPosition);Public Function GetItem(textPosition As Integer) As Page| Parameter | Description |
|---|---|
| textPosition | Specifies a zero-based text input position. |
Return Value
The return value is null, if a page could not be found. Otherwise, it is an object of the type Page.
Examples
The following example works with the laid-out pages of a short report by using PageCollection.get_Item.
textControl.Text = "Quarterly results\nRevenue increased by 12%.";
PageCollection pageCollection = textControl.GetPages();
Page result = pageCollection.GetItem(1);
result?.Select();textControl.Text = "Quarterly results" & vbCrLf & "Revenue increased by 12%."
Dim pageCollection As PageCollection = textControl.GetPages()
Dim result As Page = pageCollection.GetItem(1)
If result IsNot Nothing Then result.Select()