Filter Data from TwoD array of Dictionary type

Guys,Screenshot%20(1)
I used SharePoint custom activity for read a SharePoint list and a result is two dimensional array of dictionary<String.Object> type.

how filter specific data from this array?
Ex: there is a column - Status and with values - “Completed” and “Pending”
I want filter Completed data from the dictionary

Are there any method to resolve this problem?

Hi @RasinduLakkitha95 did you find how to solve this? I am wondering the same in this moment.

Hi @carmen,

there are two methods to filter data from sharepoint when we use sharepoint custom activity.

01) Use CAML query

there are so many tools in net to generate caml query according to our requirement.
Ex:- SMARTCAML

As example there is a column - Status and with values - pending and updated…and want filter updated data from sharepoint

Now we can use caml query like this…

Afterthat copy following xml and then paste in sharepoint readlist activity


like thiscml4

Now you can create table like sharepoint list using build data table activity like following image.

then use for each activity with Argument type => Dictionary <String,Object>…

in For each use add data row to insert data from dic to table…

in above picture, Title,Lastname,profile are sharepoint column names.when you use sharepoint column names please get the like this,

Sharepoint List => List Settings=>click list name

then use the column name in browser

Use “Title” as column name not “First name”

finally you have a data table with data which are filtered from sharepoint list…
Now you can access specific Data like
Datatablename.Rows(Rownumber).item(columnname).tostring

2 Likes

Hi @carmen,

02)Without CAML

you can get data from sharepoint to data table using above procedure except caml query… after that you can use filter data table to filter data…

thats it… hope got resolved you problem
cheers

1 Like

Also You can use this documentation

SharePoint_Custom_Activities_Documentation.pdf (1.5 MB)

thank you very much! That is all that I was needing to know.

1 Like

Hi @RasinduLakkitha95, thank you! Your solution helped me as well. Is there also another way to update a list item in Sharepoint without CAML? because I’m not familiar with CAML.

Regards