For each row google sheets

Hi, I am looking for the bot to pick the next row on google sheets once it has finished the current row. i am using for each row activity but have errors on my workflow and am not sure how i can get rid of them.

This is the current workflow i have

any help would be much appreciated.

@nick.v,

  1. Use Read Range (Google Sheet) and store the output in a data table(db1)
  2. Use For each row in db1

Regard,
Muralidhar

@MuralidharVankamaddi
am i one the right path here?

yes.

  1. For Read Range store the output in datatable variable
  2. And provide that datatable variable in For each Row

Hi @MuralidharVankamaddi thank you it work but doesn’t work. It keep doing the first row over and over it doesn’t move to the other rows, am i missing something here?

@nick.v,

Can you please remove the Invoke work file inside the loop. and put message box (row(0).tostring) and see whether data is coming row by row.

Regards.
M

image
is this what should happen?

@MuralidharVankamaddi

@nick.v

Like this in code for message box
image

@MuralidharVankamaddi when i do that i get an empty message box with an ok button

Actualy ignore that, the code is fine as the google sheet is empty for column A i tried putting the read range as A1 that has the heading and it put that in the message box.

Is it possible to share that part of the code showed in screenshot

the issue i am having it i have a process to run with column I and by the time the process is finished the data thats found on a webpage needs to be put into the empty column a,b,c,d etc
Now i don’t know how to put the 2 together now. ihave the process that needs to be run and i have a code for extracting the data from google sheet.

Anything you suggest that would help me here?
@MuralidharVankamaddi

  1. First Read range the gSheet and store in data table db1

  2. Use for each row activity and loop through db1

  3. Inside the loop write the code that your process has to run and get the data to be placed in gsheet

  4. Use write cell activity to place the value accordingly.

Note create a counter variable to increment and use it as reference in write cell.ie A+index