List information:

SharePointApplication = http://xxx/sites/Development%20Kit/CHC/_vti_bin

RootFolder = /sites/Development Kit/CHC/Lists/Code Sync Tracking/D/L1

i want get picture-3 L1 data:

Title/Sync Status ..etc

how to do it?

enter image description here enter image description hereenter image description here

my sample code

SP.ClientContext clientContext = new SP.ClientContext(url);
SP.List list = clientContext.Web.Lists.GetByTitle("Code Sync Tracking");

SP.CamlQuery camlQuery = new SP.CamlQuery();
camlQuery.ViewXml = @"<View Scope='Recursive'><Query></Query></View>";
camlQuery.FolderServerRelativeUrl = "/Code Sync Tracking/D/L1/";
SP.ListItemCollection listItems = list.GetItems(camlQuery);            
clientContext.ExecuteQuery(); <=exception happen

Microsoft.SharePoint.Client.ServerException: 'Value does not fall within the expected range.'

How do i modify the code correctly?

2 Answers 2


Go to List Settings > Export To Excel


I think you are talking about SharePoint document library not list as you have mentioned folder under list. So in order to get all your documents inventory from SharePoint library, please download the below PowerShell script which give the csv output for all your files and folders.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.