共用方式為


SPUserCodeCachedAssemblyGroup.GetFileContents method

會取得指定之檔案的內容。

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'宣告
Public Function GetFileContents ( _
    fileName As String _
) As Byte()
'用途
Dim instance As SPUserCodeCachedAssemblyGroup
Dim fileName As String
Dim returnValue As Byte()

returnValue = instance.GetFileContents(fileName)
public byte[] GetFileContents(
    string fileName
)

參數

傳回值

Type: []
包含指定之檔案的內容的位元組陣列。

Exceptions

Exception Condition
InvalidOperationException

大於最大支援的檔案大小為指定的檔案。

備註

此方法不支援包含多個MaxValue位元組或大於 2 GB 大小的檔案。

請參閱

參照

SPUserCodeCachedAssemblyGroup class

SPUserCodeCachedAssemblyGroup members

Microsoft.SharePoint.Administration namespace