In a scenario I extracted some data from a website where it has some data in it using “Table exteraction” activity So when i declare the “Extracteddatatabel” variable in the write range work book the whole data is being written in only one that’s the first cell of the excel sheet
So now! How do i get the data into individual cell in a coloumn
eg: col1 col2
Row1 ‘A1’
Row2 ‘A2’
neha.upase
(Neha Upase)
September 17, 2023, 7:36pm
2
Hi,
You can use following steps
Use the “Data Scraping” activity to extract data from a website and store it in a DataTable variable (e.g., “ExtractedDataTable”).
Assign rowNumber = 1 (Initialize the row counter)
For Each Row in ExtractedDataTable
Write Cell activity
Cell: “A” + rowNumber (This will write data to cells in column A, incrementing the row number each time)
Value: row(“ColumnName”).ToString()
(Replace “ColumnName” with the actual column name you want to write)
WorkbookPath: “path_to_your_excel_file.xlsx”
SheetName: “Sheet1” ( Replace with your sheet name)
Overwrite: True ( Set this to True if you want to overwrite existing data)
Assign rowNumber = rowNumber + 1 (Increment the row counter)
Hi
Ideally it would write in all the cells
Would recommend to check and make sure you are performing these
Use WRITE RANGE WORKBOOK activity
Enable add headers property in the property panel
Pass the datatable extracted as input
Mention as “A1” in the cell range so that it starts to write from first cell
Cheers @Nithin_Thatikonda
Anil_G
(Anil Gorthi)
September 18, 2023, 2:32am
4
@Nithin_Thatikonda
One cause might be when extracting data all the data might be coming as one…please re indicate it in table extraction properly
Cheers