Reflection Desktop VBA Guide
Attachmate.Reflection.Objects.Emulation.OpenSystems Library / Attachmate.Reflection.Objects.Emulation.OpenSystems Library / Screen Object / DisplayRows Property
Example
In This Topic
    DisplayRows Property
    In This Topic
    Gets or sets the number of lines in each page of display memory.
    Syntax
    expression.DisplayRows As Integer
    where expression is a variable that represents a Screen Object
    Remarks
    The host can position the cursor and write characters on any row in the specified range.
    Example
    This example finds the position (row and column) of a string on a screen. To run this sample, create a VT session with the host name/IP address set to demo:unix. Then enter any text for credentials and enter demodata to navigate to the XYZ Company Sales screen. Enter and run this code in a code module.
    'This example finds the position (row and column) of a string on a screen
    Sub ExampleForSearchText4()
     
        Dim sPoint As ScreenPoint
        Dim text As String
        Dim row, column As Integer
        
        'Get the maximum rows for the screen
        row = ThisScreen.DisplayRows
        column = ThisScreen.DisplayColumns
        
        'Find the row
        Set sPoint = ThisScreen.SearchText4("Profit", 1, 1, row, column, FindOptions_Forward, TextComparisonOption_IgnoreCase)
        
        'Get the Text
        text = ThisScreen.GetText(sPoint.row, sPoint.column, 8)
        
        Debug.Print text; " is at row " & sPoint.row & " and column " & sPoint.column
        
    End Sub
    See Also