Lookup datatable issue

I am running a data table lookup but getting the following error. “Wrong variable type assigned to ‘Found Cell Value’. It is ‘System.String’ but it should be”

even tho i have created the ouput cell value as a string varaible type


Please check the variable type once and if required you can also convert the variable type.

Delete the variable. Clear out the “Found Cell Value” property. Put your cursor into Found Cell Value and press CTRL+K. Type the variable name and press enter. Adjust the scope of the variable if needed. This is the best way to create variables for activities, as it automatically creates it with the correct datatype.

Thanks, I have used the same approach but it still did not work

What does “did not work” mean? If you’re getting an error, post the complete error.


Welxome to the community

Try using a genericvalue type variable and check…as the found cell value type will be of the column type value…

You can then convert to required type from genericvalue type


The variable entered into the property should match what the property expects, which is String.

I have a similar issue in a from legacy to windows type migrated project.

The automation ran for more than 3 years without issues on legacy, but after migrating to windows type at one stage the Lookup Data Table goes mad. It states that it does not like the string variable anymore, but wants a object now for the ‘Found Cell Value’.


I changed the variable to type object and this works for now. Of course I have to do the needed conversion afterwards in the flow to work with the adapted variable.

I had the same problem, and I solved it by updating the UiPath.System.Activities package to an older version (24.3.0).