File.SaveBinaryDirect 方法 (ClientContext, String, Stream, String)
上傳至 SharePoint 網站與指定 Etag 而不需要進行ExecuteQuery()方法通話的指定的檔案。
命名空間: Microsoft.SharePoint.Client
組件: Microsoft.SharePoint.Client (在 Microsoft.SharePoint.Client.dll 中)
語法
'宣告
Public Shared Sub SaveBinaryDirect ( _
context As ClientContext, _
serverRelativeUrl As String, _
stream As Stream, _
etag As String _
)
'用途
Dim context As ClientContext
Dim serverRelativeUrl As String
Dim stream As Stream
Dim etag As StringFile.SaveBinaryDirect(context, serverRelativeUrl, _
stream, etag)
public static void SaveBinaryDirect(
ClientContext context,
string serverRelativeUrl,
Stream stream,
string etag
)
參數
context
類型:Microsoft.SharePoint.Client.ClientContext表示 SharePoint 網站的伺服器內容ClientContext物件。
serverRelativeUrl
類型:System.String表示檔案的伺服器相對 URL 的字串。
stream
類型:System.IO.Stream表示檔案Stream物件。
etag
類型:System.StringSharePoint server 的 Etag (實體標記) 表示的字串。