Read Range of Excel and write to a different cell using same Excel file

Hello, I am needing one help for this job please and if be possible, one example
Using the Excel file in attached, I am reading ALL values of “A” Cell and depending the value into this cell, I need put the “Situation” into the cell (“E”).
I am getting to write ONLY the first row and iteration is not working for others rows.
I tried put in Write Cell, “E2” + VAR1 but it not working)

My main activities are:
Variables:: InputDataTable , CodeValue, ContentValue e VAR1.

1- Excel Application Scope
2- Read range the Excel File. (var: InputDataTable)
4-For Each Row.
5- Assign ( CodeValure = row(“CNPJ”).ToString.Trim)
6- If condition (CodeValue = “02773629000280”)
7- THEN Write Cell (“E2”) “OK” ELSE Write Cell “NOK”
8- Assign (VAR1 = VAR1 + 1)

Could you please give me one example for this iteration and IF CONDITION?

Test.xlsx (9.1 KB)


Hope the following helps you.


Hello, the process is writing in incorrect CELL as attached. The index was created and put as recomended.
Could you assist me with attached?

Sequence.xaml (9.5 KB)


My expression is "E"+(index+2).ToString in the above workflow. Can you use this? (Your expression is "E2"+(index+2).ToString )


Hello, I fixed it, putt in cell, only “E” plus the index.


1 Like