code: public int getRowIndex(String searchElement, int startRowIndex) {
          int index = -1;
          if (ready()) {
              String path = getGridCell(startRowIndex).getXPath();
              WebLocator currentElement = new WebLocator().setElPath(path);
              while (currentElement.isElementPresent()) {
                  String option = currentElement.getText();
                  //LOGGER.debug("row[" + i + "]" + option);
                  if (option != null && option.contains(searchElement)) {
                      LOGGER.debug("The '" + searchElement + "' element index is " + startRowIndex);
                      index = startRowIndex;
                      break;
                  }
                  startRowIndex++;
                  path = getGridCell(startRowIndex).getXPath();
                  currentElement.setElPath(path);
              }
              if (index == -1) {
                  LOGGER.warn("The element '" + searchElement + "' was not found.");
              }
          } else {
              LOGGER.warn("getRowIndex : grid is not ready for use: " + toString());
          }
          return index;
      }
docs: this method is working only for normal grids (no buffer views), and first page if grid has buffer view