How get the number of row in Data logger Windows

How get the number of row in Data logger Windows

  • 25 Januar 2020 um 2:25 pm #35462
    [email protected]
    Teilnehmer

    Hi, I use script to filter the mysql database and display in Datalogger windows. I want to know the number of row after filter.How can i get this data?

  • 29 Januar 2020 um 10:00 am #35478
    Joseph
    Teilnehmer

    Hi Jeff,
    In these cases I usually use the grid object instead of the DL Windows because it is more flexible.
    It has this function embedded in the script interface.

    GetRowCount, GridWndCmdTarget Function

    Description
    This function get the number of rows loaded into the grid object. The number of rows correspond to the number of records retrieved by the selection query when connected to a database, or the number of rows existing in a linked text file.

    E.g.

    ***
    Dim objGrid As GridWndCmdTarget
    Public Sub Click()
    objGrid.Query = „SELECT * FROM DataLogger00001 WHERE VAR00001 >= 5“
    objGrid.Refresh
    End Sub

    Public Sub SymbolLoading()
    Set objGrid = GetSynopticObject.GetSubObject(„Grid1“).GetObjectInterface
    End Sub

    ***
    ‚Button environment

    Dim objGrid As GridWndCmdTarget

    Public Sub Click()
    Debug.Print objGrid.GetRowCount
    End Sub

    Public Sub SymbolLoading()
    Set objGrid = GetSynopticObject.GetSubObject(„Grid1“).GetObjectInterface
    End Sub

    Best Regards
    Joseph

Du musst angemeldet sein, um auf dieses Thema antworten zu können.