ReportingService2010.SetItemHistoryLimit 方法

Specifies the number of snapshots of an item that the report server retains. This method applies to the Report item type.

命名空间:  ReportService2010
程序集:  ReportService2010(在 ReportService2010.dll 中)

语法

声明
<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/SetItemHistoryLimit", RequestNamespace := "https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer",  _
    ResponseNamespace := "https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer",  _
    Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
<SoapHeaderAttribute("TrustedUserHeaderValue")> _
<SoapHeaderAttribute("ServerInfoHeaderValue", Direction := SoapHeaderDirection.Out)> _
Public Sub SetItemHistoryLimit ( _
    ItemPath As String, _
    UseSystem As Boolean, _
    HistoryLimit As Integer _
)
用法
Dim instance As ReportingService2010 
Dim ItemPath As String 
Dim UseSystem As Boolean 
Dim HistoryLimit As Integer

instance.SetItemHistoryLimit(ItemPath, _
    UseSystem, HistoryLimit)
[SoapDocumentMethodAttribute("https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/SetItemHistoryLimit", RequestNamespace = "https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", 
    ResponseNamespace = "https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", 
    Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
[SoapHeaderAttribute("TrustedUserHeaderValue")]
[SoapHeaderAttribute("ServerInfoHeaderValue", Direction = SoapHeaderDirection.Out)]
public void SetItemHistoryLimit(
    string ItemPath,
    bool UseSystem,
    int HistoryLimit
)
[SoapDocumentMethodAttribute(L"https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/SetItemHistoryLimit", RequestNamespace = L"https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", 
    ResponseNamespace = L"https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", 
    Use = SoapBindingUse::Literal, ParameterStyle = SoapParameterStyle::Wrapped)]
[SoapHeaderAttribute(L"TrustedUserHeaderValue")]
[SoapHeaderAttribute(L"ServerInfoHeaderValue", Direction = SoapHeaderDirection::Out)]
public:
void SetItemHistoryLimit(
    String^ ItemPath, 
    bool UseSystem, 
    int HistoryLimit
)
[<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/SetItemHistoryLimit", RequestNamespace = "https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", 
    ResponseNamespace = "https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer", 
    Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)>]
[<SoapHeaderAttribute("TrustedUserHeaderValue")>]
[<SoapHeaderAttribute("ServerInfoHeaderValue", Direction = SoapHeaderDirection.Out)>]
member SetItemHistoryLimit : 
        ItemPath:string * 
        UseSystem:bool * 
        HistoryLimit:int -> unit
public function SetItemHistoryLimit(
    ItemPath : String, 
    UseSystem : boolean, 
    HistoryLimit : int
)

参数

  • ItemPath
    类型:System.String
    The fully qualified URL of the item including the file name and, in SharePoint mode, the extension.
  • UseSystem
    类型:System.Boolean
    A Boolean expression that, when set to true, sets the item history limit to the current system item history limit. A value of false indicates that the item history limit corresponds to the value supplied in the HistoryLimit parameter.
  • HistoryLimit
    类型:System.Int32
    The number of item history snapshots to store for the item. Values can range from -1 to 2,147,483,647. If the value is set to –1, all item snapshots are saved.

注释

The table below shows header and permissions information on this operation.

SOAP Header Usage

(In) TrustedUserHeaderValue

(Out) ServerInfoHeaderValue

Native Mode Required Permissions

UpdatePolicy

SharePoint Mode Required Permissions

EditListItems

This method only supports the Report item type. Specifying the URL of any item other than a report causes the method to throw an exception with the exception string "Wrong Item Type".

If the UseSystem parameter is set to true, the report server ignores the HistoryLimit parameter.

注意注意

If the value of HistoryLimit is changed, item history snapshots may be deleted.   

请参阅

参考

ReportingService2010 类

ReportService2010 命名空间