Separate Files for unique code

how to find unique code values in column “Co Code”. Create a separate file for each value with the records for that unique code value. E.g all records for unique code 1GH should be in one file
Some of other unique code in column “Co Code” will separate in other file and save each file in new excel…
thanks in advance.Unique_code.xlsx (8.4 KB)

So for unique values in column “Co Code”, you can use:

datatable.defaultvalue.totable(false,“Co Code”)

You can then loop through this datatable of a single column in a for each row:
Then filter the whole datatable by row.item(0).ToString -
This will retrieve all your rows with e.g. 1GH

You can then use write range activity - to create a new file for all those rows. etc.

Hope that helps :slight_smile:

thankyou for your help it worked…

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.