Click or drag to resize
ISharePointFileServiceGetFile Method
Gets SharePoint file identified by server relative URL. The file may be loaded eagerly or lazily (depends on implementation). In such case an invalid serverRelativeUrl is not reported immediately.

Namespace: CMS.SharePoint
Assembly: CMS.SharePoint (in CMS.SharePoint.dll) Version: 10.0.0
Syntax
C#
ISharePointFile GetFile(
	string serverRelativeUrl
)

Parameters

serverRelativeUrl
Type: SystemString
Server relative URL

Return Value

Type: ISharePointFile
SharePoint file, or null
Exceptions
ExceptionCondition
FileNotFoundExceptionThrown when requested file is not present at SharePoint server (and eager loading is used).
SharePointServerExceptionThrown whenever server error occurs.
WebExceptionThrown when error related to network or protocol occurs.
SharePointConnectionNotSupportedExceptionThrown when given connectionData contains unsupported authentication mode or invalid URL.
SharePointCCSDKExceptionThrown when identity client library "msoidcliL.dll" needed for SharePoint Online authentication is missing. See documentation for details.
ExceptionThrown in case of unexpected error condition.
See Also