How can i write a cell on this row?

I’m on a FOR loop and i successfully loaded data from an excel file but now i need to write something on it so… how do i write a cell on the current row?

This is what i’ve done until now:

Thank you in advance

Hi, here is one way to do it

Library  RPA.FileSystem
Library  RPA.Tables

*** Keyword ***
Process a row
    [Arguments]  ${table}  ${row}  ${index}
    Set table cell  ${table}  ${index}  name  foo_${row}[name]

*** Task ***
Minimal task
    ${files}  List files in directory  .

    ${table}  Create table  ${files}
    FOR  ${index}  ${row}  IN ENUMERATE  @{table}
        Process a row  ${table}  ${row}  ${index}
1 Like

Thank you , but actually i need to write on an excel file, not in a table

For that i’m using RPA.Excel.Application, and obviously im doing something wrong because it’s not working

i leave an image in case you can help me out with this one too

i’m getting “None”, i dont know why


You are mixing keywords between RPA.Excel.Files and RPA.Excel.Application. If you don’t have specific need I would recommend to use RPA.Excel.Files library to handle Excel files, because it works crossplatform and thus can run also on the cloud container. Where as RPA.Excel.Application library requires WIndows machine with Excel installed.

1 Like

Here is a minimal example of using RPA.Excel.Files

*** Settings ***
Library  RPA.Excel.Files

*** Task ***
Minimal task
    Open workbook  my_excel.xlsx
    FOR  ${row}  IN RANGE  1  5
        ${value}=  Get worksheet value  ${row}  A
        Set worksheet value  ${row}  B  ${value+1}
    Save workbook


1 Like