Excel Read Range Activity reading data type as object

Hello Everyone,

I am reading an excel file which has many columns in a general type format. Read range activity reading all columns as object type even if i change excel column type to string. i dont know how but uipath reading only two cells (they are general type too) as a string type and the rest is object. I ve checked the datatable and also added here as an attachment. So i cant use filter datatable activity in object columns. Is there a bug in read range activity? Why is that two string and the others are object? What is logic here? All the given are the sentences and words except some. if i give input like “abc” , filter datatable not match. I cant give just abc so i am stuck a little bit. I am really wondering it.

Thank you.

Note: I can solve my problem using select or with some linq but i want to use filter datatable. I dont wanna use the preserve format which is too slow.

Excel Activity version is 2.9.5. Studio version is 2020.4.3



Did we try with workbook activities instead of excel activity

Also try once upgrading the excel package to the latest version

Cheers @Nurullah_Kus

I tried now but didnt work. It seems like datatable activities only works for known column types. At least Uipath should provide us an official column type changer activitiy. I am solving most problems with some hardcoded linqs or .net methods etc. It is good to use .net but time consuming sometimes. Some useful features are added but the development still not fast as fast it should be.

Actually excel will read all the values as string only

IBM wondering how it is taking as object

Did we try upgrading the excel package to the latest version


Yes i ve tried latest version. Column type is shown as system.object. I ve used dt.asenumerable.where().copytodatatable to solve. I ve converted to string inside.

1 Like

Yeah that’s fine
And linq query to fo that

Use a assign activity like this

dt = (From row In dt.Select Order By row(“your ColumnName”).ToString) Ascending Select row).ToArray.CopyToDatatable()

Cheers @Nurullah_Kus