How to write on a cell column name based

hi to the whole community
could someone give me a hand?
I would like to write some data inside the bascelomi excel sheet on the column name, but I do not know how to do it. I would be very grateful if you gave me a mane.

Thanks in advance

@momi_fede what u want to write in this excel sheet exactly. can u be more specific?

on the first column I would like to insert some codes, for example: 1234, 5678, 9012 etc …
in the other two my name and surname

@momi_fede u can use add data Row activity

Hey @momi_fede
If you want to write only one row the easiest way would be to use write cell activity

Please refer to the workflow attached :slight_smile:

Excel_Operations (1).xaml (8.0 KB)



how can i implementing this?

thank for your replace, but i want to write a row column name based

From what source are you getting the values from which you want to write in the excel file?

from a string values

What you can do is that you can create a datatable and then add those string values in the data table…then pass that data table in write range for the particular excel file…

I have to write my data on an existing excel file

Try this

Excel_Operations (1).xaml (9.2 KB)

You’ll have to use either of the two methods
It’s always a good option to fetch the data with column names but while adding something you’ll have to use something like this

if you have some data already saved in the excel just use Append Range activity instead of read range…
If it does not have any values, then just use read range as I told you

I sent the above message before i read this, in place of read range use append range if you want to add to an existing file

How can I write to a column using its column name…I know we can give range as cell number but I want to write to the column based on the header…like I want to look for the column with that particular header and then write data under that column…I’m not able to find out the solution please can someone help

To answer the original question - I don’t think it is possible to refer to a column in excel by the name using excel activities. In order to use the header you have to read into a datatable, write to the item there (using .item(“columnname”)) and export this to excel, overwriting the entire sheet.

This is probably inefficient for large spreadsheets and introduces type conversion concerns.

Ideally, you would be able to refer to a cell using .column(coumnname") or similar rather than the “A”, “B” or so on.