Excel: row Length> 16 within for each row, works but the loop restarts unexpectedly and then fails


In Excel, if there are rows with more than 16 characters, I delete them from that sheet and copy them to another.

Everything works fine, but when finished it restarts the validation and then fails because there are no more rows that meet the criteria below:

Assign: dtOutput1

(dtInput.AsEnumerable (). Where (Function (row) row ("Invoice-Number"). ToString.Length> 16) .CopyToDataTable)

What am I doing wrong?

Check 2 things:

Make sure that excel files does not have a cell with a space values be sure to clear out all row after the last line on the excel document

If you are using AsEnum make sure your Enum value start at 0 and not 1. This can cause to run additional validate step.


Can you try to put Break activity as the following?



@Yoichi It works now! Thank you :blush:

1 Like

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