How to split an excel file into another excel file with multiple sheets using values from the column

hi good evening dear developers, i have a scenario the excel file is like this
i want to split this sample table into another excel file with multiple sheets using the index value renaming the sheet with the index. the outcome should be like this

each worksheet belong to an index from the sample table. thank you so much in advance, hope someone helps me.


Check this one, it has the functionality you are looking.
SplitExcelData2Sheets.xaml (6.4 KB)

1 Like

Firstly you want to ready the datatable.

Then you can use a for each loop to create each new sheet (with index name) and write the name / index onto each sheet (use Write Range and add row.item(“Index”).ToString as sheetname)

The range it will be “B1”

For Datatable, you will need to just get the current row.
Table.Select(“Index ='”+row.Item(“Index”).ToString+“'”).copytodatatable

1 Like

hi dear timk, thank you so much for response. could you show a sample workflow on how to do this?

1 Like


Kindly check the post and the xaml I have shared in this thread.


thank you sir. i will try and get back to you.