You can use the column numbers instead of column names.
You can get the number of columns present using DataTableName.Columns.Count
You can then use a while loop inside the ForEachRow activity to trim the values of each cell.
PFA the sample workflow.
Forum_DtWhitespaceFilter.zip (27.9 KB)