Try to use this endpoint GetFolderByServerRelativeUrl to return all files and folder at a specific folder URL
To return only all files at a specific folder URL
For more ...
I was able to find the cause of the issue, the particular site collection is part of a farm that was not updated and does not include the February 2015 cu update.
So I had to build a method to support both scenarios, if the getList() method is not available it will do the fall back method and will use the older method get_lists().
I ended up doing this ...
I finally found the answer I was looking for thanks to this Blog.
I deleted the CAML Query settings :
<FieldRef Name='FileDirRef'/><Value Type='Lookup'>SubFolder1</Value>
and added this line to my CAML Query Options ...
In the flow, there's an "Get item" action. You could use it to get the most recently created one.
1.Create a flow, choose the trigger "When an item is created"
2.Then in the next step, choose the "Get item" action. Note: Make sure you choose get item instead of get items.
In the action, choose the list and ID
When using SharePoint Online, you should be using REST, not SOAP. REST is more modern and supports authentication scenarios such as those required by SharePoint Online, that is: claims-based authentication. Furthermore it’s responses are returned as JSON objects which do not carry the excessive overhead of XML, and therefore tend to return ...
Try below code if you want to keep using the body as rich text field:
private void DisplaySelectedListItem()
string siteUrl = SPContext.Current.Web.Url;
int id = int.Parse(Request.QueryString["ID"]);
using (SPSite spSite = new SPSite(siteUrl))
using (SPWeb web = spSite.OpenWeb())
SPList list = web....
The query you are using will return all items irrespective of type (folder/file). You can use change to below syntax.
_spPageContextInfo.webAbsoluteUrl + "/_api/web/getfolderbyserverrelativeurl('<<folder relative path>>')/Files
Example for folder relative path is
/[subsite]/<<library name>>/<<folder name>>
You can use the SPList.ContentTypes property to check if it contains your custom content type "Birthday" and apply your business logic to that list
An example from MSDN: https://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spcontenttypecollection.bestmatch.aspx