Quantcast
Channel: SharePoint 2013 - Development and Programming forum
Viewing all articles
Browse latest Browse all 7589

How to get list items from folder using REST API

$
0
0

Hi,

I want to retrieve list items from particular folder within SharePoint list.

Using following code

var camlQuery = new SP.CamlQuery();
camlQuery.set_viewXml('<Query></Query>'); //Sample query

var executor = new SP.RequestExecutor(appweburl);

                executor.executeAsync(
                    {
                        url:appweburl+"/_api/web/lists/GetByTitle('"+vListName +"')/getItems('"+camlQuery+"')",
                        method: "POST",
                        headers: { "Accept": "application/json; odata=verbose"},
                        success: getListItemsSuccess,
                        error: getListItemsFail
                    }
                );

Referring this link :http://msdn.microsoft.com/en-us/library/jj245102.aspx

Getting error message : Not well formatted JSON stream.

Is there any other way to achieve this?


Thanks, Neha Navale


Viewing all articles
Browse latest Browse all 7589

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>