Condividi tramite


Metodo ReportingService2010.GetExtensionSettings

Returns a list of settings for a given extension.

Spazio dei nomi  ReportService2010
Assembly:  ReportService2010 (in ReportService2010.dll)

Sintassi

'Dichiarazione
<SoapHeaderAttribute("TrustedUserHeaderValue")> _
<SoapHeaderAttribute("ServerInfoHeaderValue", Direction := SoapHeaderDirection.Out)> _
<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/GetExtensionSettings", 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)> _
Public Function GetExtensionSettings ( _
    Extension As String _
) As ExtensionParameter()
'Utilizzo
Dim instance As ReportingService2010 
Dim Extension As String 
Dim returnValue As ExtensionParameter()

returnValue = instance.GetExtensionSettings(Extension)
[SoapHeaderAttribute("TrustedUserHeaderValue")]
[SoapHeaderAttribute("ServerInfoHeaderValue", Direction = SoapHeaderDirection.Out)]
[SoapDocumentMethodAttribute("https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/GetExtensionSettings", 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)]
public ExtensionParameter[] GetExtensionSettings(
    string Extension
)
[SoapHeaderAttribute(L"TrustedUserHeaderValue")]
[SoapHeaderAttribute(L"ServerInfoHeaderValue", Direction = SoapHeaderDirection::Out)]
[SoapDocumentMethodAttribute(L"https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/GetExtensionSettings", 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)]
public:
array<ExtensionParameter^>^ GetExtensionSettings(
    String^ Extension
)
[<SoapHeaderAttribute("TrustedUserHeaderValue")>]
[<SoapHeaderAttribute("ServerInfoHeaderValue", Direction = SoapHeaderDirection.Out)>]
[<SoapDocumentMethodAttribute("https://schemas.microsoft.com/sqlserver/reporting/2010/03/01/ReportServer/GetExtensionSettings", 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)>]
member GetExtensionSettings : 
        Extension:string -> ExtensionParameter[] 
public function GetExtensionSettings(
    Extension : String
) : ExtensionParameter[]

Parametri

  • Extension
    Tipo: System.String
    The name of the extension as it appears in the report server configuration file. Valid values are Report Server Email, Report Server DocumentLibrary and Report Server FileShare.

Valore restituito

Tipo: array<ReportService2010.ExtensionParameter[]
An array of ExtensionParameter objects that represent the list of known settings for a given extension.

Osservazioni

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

SOAP Header Usage

(In) TrustedUserHeaderValue

(Out) ServerInfoHeaderValue

Native Mode Required Permissions

None

SharePoint Mode Required Permissions

None

If the extension does not support any extension parameters, an empty list is returned.

[!NOTA]

Currently, the GetExtensionSettings method supports delivery extensions. Other extensions are not yet supported by this method.

Esempi

using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;

class Sample
{
    static void Main(string[] args)
    {
        ReportingService2010 rs = new ReportingService2010();
        rs.Url = "http://<Server Name>" + 
            "/_vti_bin/ReportServer/ReportService2010.asmx";
        rs.Credentials = 
            System.Net.CredentialCache.DefaultCredentials;

        ExtensionParameter[] extensionParams = null;

        try
        {
            extensionParams = 
                rs.GetExtensionSettings(
                    "Report Server DocumentLibrary");

            Console.WriteLine("Settings retrieved.");

            if (extensionParams != null)
            {
                foreach (ExtensionParameter extensionParam 
                    in extensionParams)
                {
                    Console.WriteLine("Value: {0}", 
                        extensionParam.Value);
                    Console.WriteLine("Name: {0}", 
                        extensionParam.Name);
                    Console.WriteLine("ReadOnly: {0}", 
                        extensionParam.ReadOnly);
                    Console.WriteLine("Required: {0}", 
                        extensionParam.Required);
                }
            }
        }

        catch (SoapException e)
        {
            Console.WriteLine(e.Detail.InnerXml.ToString());
        }
    }
}
Imports System
Imports System.IO
Imports System.Text
Imports System.Web.Services
Imports System.Web.Services.Protocols

Class Sample

    Public Shared Sub Main()

        Dim rs As New ReportingService2010()
        rs.Url = "http://<Server Name>" + _
            "/_vti_bin/ReportServer/ReportService2010.asmx"
        rs.Credentials = _
            System.Net.CredentialCache.DefaultCredentials

        Dim extensionParams As ExtensionParameter() = Nothing

        Try
            extensionParams = _
                rs.GetExtensionSettings("Report Server " + _
                    "DocumentLibrary")

            Console.WriteLine("Settings retrieved.")

            If Not (extensionParams Is Nothing) Then
                Dim extensionParam As ExtensionParameter
                For Each extensionParam In extensionParams
                    Console.WriteLine("Value: {0}", _
                        extensionParam.Value)
                    Console.WriteLine("Name: {0}", _
                        extensionParam.Name)
                    Console.WriteLine("ReadOnly: {0}", _
                        extensionParam.ReadOnly)
                    Console.WriteLine("Required: {0}", _
                        extensionParam.Required)
                Next extensionParam
            End If

        Catch e As SoapException
            Console.WriteLine(e.Detail.InnerXml.ToString())
        End Try

    End Sub

End Class

Vedere anche

Riferimento

ReportingService2010 Classe

Spazio dei nomi ReportService2010