File.SaveBinaryDirect - Méthode (ClientContext, String, Stream, Boolean)
Uploads the specified file to a SharePoint site without requiring an ExecuteQuery() method call.
Espace de noms : Microsoft.SharePoint.Client
Assembly : Microsoft.SharePoint.Client (dans Microsoft.SharePoint.Client.dll)
Syntaxe
'Déclaration
Public Shared Sub SaveBinaryDirect ( _
context As ClientContext, _
serverRelativeUrl As String, _
stream As Stream, _
overwriteIfExists As Boolean _
)
'Utilisation
Dim context As ClientContext
Dim serverRelativeUrl As String
Dim stream As Stream
Dim overwriteIfExists As BooleanFile.SaveBinaryDirect(context, serverRelativeUrl, _
stream, overwriteIfExists)
public static void SaveBinaryDirect(
ClientContext context,
string serverRelativeUrl,
Stream stream,
bool overwriteIfExists
)
Paramètres
context
Type : Microsoft.SharePoint.Client.ClientContextA ClientContext object that represents the SharePoint site’s server context.
serverRelativeUrl
Type : System.StringA string that represents the server-relative URL of the file.
stream
Type : System.IO.StreamA Stream object that represents the file.
overwriteIfExists
Type : System.BooleanA Boolean value that specifies whether the file is overwritten if it already exists.