In order to access some SharePoint data I use the Microsoft.SharePoint.Client Library which exposes the following api. There are example usage in C# (link) from which is the following snippet:
ClientContext context = new ClientContext("http://SiteUrl");
Web web = context.Web;
context.Load(web.Lists,
lists => lists.Include(list => list.Title, // For each list, retrieve Title and Id.
list => list.Id));
The Signature of the Load method is (link)
public void Load<T>(
T clientObject,
params Expression<Func<T, Object>>[] retrievals
)
where T : ClientObject
Fsharp Compiler expect the second paramater to be of type
Linq.Expressions.Expression<Func<'a,obj>>
or
Linq.Expressions.Expression<Func<'a,obj>> []
Can I use the Load
Method from F# and how ?
There is a related answer here
but I cant translate the give code example solution to the above c# example.
Maybe one can help?
The types involved are list : ListCollection
and list : List