Click or drag to resize
SharePointFileInfoProviderUploadFileInternal Method
Uploads a new file to the specified SharePoint library. The newly uploaded file is immediately available both on the SharePoint server and locally in the library.

Namespace: CMS.SharePoint
Assembly: CMS.SharePoint (in CMS.SharePoint.dll) Version: 8.2.23
Syntax
C#
protected virtual void UploadFileInternal(
	SharePointLibraryInfo libraryInfo,
	Stream contentStream,
	string libraryRelativeUrl
)

Parameters

libraryInfo
Type: CMS.SharePointSharePointLibraryInfo
SharePoint library to which the file is uploaded.
contentStream
Type: CMS.IOStream
Stream containing binary data of the file.
libraryRelativeUrl
Type: SystemString
Relative URL of the file within library (i.e. "myPicture.jpeg" uploads file to the root folder of the library).
Exceptions
ExceptionCondition
SharePointConnectionNotFoundExceptionThrown when the SharePoint library has no valid connection defined (is read-only).
SharePointFileAlreadyExistsExceptionThrown when libraryRelativeUrl already exists.
See Also