Use Read Range to read the input Excel into a DataTable
Use a For Each Row in DataTable loop.
Inside the loop, create a new DataTable with the same schema using dt.Clone().
Import the current row into the new DataTable using dtNew.ImportRow(row).
Use Write Range to write dtNew to a new Excel file. Generate the file name dynamically, for example:
Output_1.xlsx
Output_2.xlsx
Output_3.xlsx
This will create one Excel file per row. So if the input contains 5 rows, the workflow will generate 5 Excel files, each containing a single row (and the headers).
If you’re using the Modern Excel activities you can achieve the same logic with Use Excel File → Read Range → For Each Excel Row/DataTable Row → Write Range while dynamically creating the output file name inside the loop.
@sushmithaelluru
Try this
Read Range
↓
counter = 1
↓
For Each Row in DataTable
Assign finaldt = Erp_Ready_Dt.Clone()
Invoke Method (ImportRow)
Write Range ← MUST be inside the loop
Assign counter = counter + 1
End For
Your Excel file is being generated successfully, but it is overwritten for each row because the output file name is always Final.xlsx. Since the file name remains the same, the Write Range activity replaces the existing file whenever it finds a file with that name in the target folder. To avoid this, use a unique file name for each iteration (for example, by appending the row number, timestamp, or another unique identifier).