Excel Automation in Uipath

Hi I want to filter the table by Product Price whose value greater than “$5” by using Filter Data Table activity and save the filtered table
But How to do that .
How to remove “$” sign from price using filter Table activity and write the updated data table

Variable = Variable.Replace(“$”,“”)
apply this after that use filter data table

Hope this may help you


Hi @Aima_Arif

Try using this:


dt.AsEnumerable().Where(Function(row) CInt(row(“Column1”).ToString.Replace(“$”, String.Empty)) > 5).CopyToDataTable

dt2 is your new datatable with filtered values.
dt is the data table you want to filter
Column1 is the name of the column to search the values

dt.AsEnumerable().ToList.ForEach(Sub(row) row(“Column1”) = row(“Column1”).ToString.Replace(“$”, String.Empty))

you set dt as In/Out argument and assign value of dt2 to it.

You could also remove the $ inside the loop and use filter then.

dt is your datatable, dt1 is the data table after filtering.