Hi all, my doubt is there are two Excel files like previous file and present file i want to compare the files and remove the same data present in previous file in present file can any body provide the solution
Use Remove Dupicates Activity under excel process scope in Modern Experience.
Check out this below thread too
It may help you.
- Use the “For Each Row” activity to loop through each row in
- Inside the loop, use the “For Each Row” activity again to loop through each row in
- Use an “If” condition to compare the data in the current rows from both data tables. You can use the column values or any unique identifier for comparison.
- If the data in the current rows of both data tables matches, use the “Remove Data Row” activity to remove the row from
- After both loops, you will have
dtPresentFilewith the same data as the present file but with the data that was in the previous file removed.
Use this linq query:
filteredRows = dt1.AsEnumerable().Where(Function(row) Not dt2.AsEnumerable().Any(Function(prevRow) prevRow(commonColumn).ToString() = row(commonColumn).ToString())).CopyToDataTable()