Hello,
I am are encountering an issue while attempting to retrieve a SharePoint List using activities from the UiPathTeam.SharePoint.Activities v2.0.1 package within a C# Windows Project. Our environment is based on SharePoint Server (Classic) 2019 On-Premises.
The specific activity in question is:
UiPathTeam.SharePoint.Activities.List.ReadListItems (also known as Get List Items), where we are assigning the output to a variable of type:
Array<Dictionary<string, object>>.
However, at runtime, the following error is thrown:
Get List Items: A value of type ‘System.Collections.Generic.List1[System.Collections.Generic.Dictionary2[System.String,System.Object]]’ cannot be set to the location with name ‘ItemsDictArray’ because it is a location of type ‘System.Collections.Generic.Dictionary`2[System.String,System.Object][]’.
Creating the output variable using the Ctrl+K shortcut within the Items (Dictionary Array) output field also results in the same error. Notably, this issue is not detected at compile time and only occurs during runtime execution.
We also attempted to use a variable of type:
List<Dictionary<string, object>>
but this results in the following compile-time error:
Argument ‘ItemsDictArray’: CS0029: Cannot implicitly convert type ‘System.Collections.Generic.Dictionary<string, object>[]’ to ‘System.Collections.Generic.List<System.Collections.Generic.Dictionary<string, object>>’
While setting the output to a DataTable works without issue, this approach is not suitable due to its limitations with Person-type columns in our SharePoint List.
For reference, we have previously used this same set of activities successfully in VB.NET Windows Projects with UiPathTeam.SharePoint.Activities v1.7.0 against the same SharePoint Server environment, without encountering this error.
Could you please investigate this issue with the Get List Items activity in v2.0.1?
