Getting error message "Server relative urls must start with SPWeb.ServerRelativeUrl"

Copper Contributor



We have written a code of WebApi to load SharePoint folders using client Context.


We have written following code to LOAD SharePoint folders.
Folder folder = clientContext.Site.RootWeb.GetFolderByServerRelativeUrl(relativeURL);


AND we are getting below error when the we run the Execute method. "Server relative urls must start with SPWeb.ServerRelativeUrl". Please help us to resolve the same.


Does anyone have any ideas about this error? Any help would be greatly appreciated.



0 Replies