Advertisement
Guest User

Untitled

a guest
Jun 25th, 2019
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. // extract number of rows
  2. var rows = parseInt(document.evaluate("//*[@class='ag-status-panel-filtered-row-count']/child::*[@class='data_rows']",document.body, null, 9, null).singleNodeValue.textContent);
  3.  
  4. var list_data = [];
  5. // iterate rows and extract data from cell
  6. for (i=0; i < value; i++) {
  7. document.evaluate(`//*[@row-index='${i}']/descendant::*[@role='gridcell' and @col-id='data_to_extract']`,document.body, null, 9, null).singleNodeValue.focus();
  8. list_data.push(document.evaluate(`//*[@row-index='${i}']/descendant::*[@role='gridcell' and @col-id='data_to_extract']`,document.body, null, 9, null).singleNodeValue.textContent);
  9. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement