Forum Discussion

David91's avatar
David91
Frequent Contributor
8 years ago

Variables Table - Findrow method

Hi,   I want search data (string) from my variable table. etc. I search neame David in column Name. Can i get row number from variable table?   Thank you
  • baxatob's avatar
    8 years ago

    Hi,

     

    You can add a counter to your search cycle:

     

    def search_in_table(name):
    table = Project.Variables.yourTableVar
    table.Reset() counter = 1 #consider that first row contains column names while not table.isEOF(): counter += 1 if table.Value["Name"] == name: Log.Message(counter) table.Next()