IAdmReportPinning

The IAdmReportPinning interface is used to manage reports pinned for the currently logged on user.

Inheritance: IUnknown

To use the IAdmReportPinning interface, you need to bind to a report.

Methods

  • Method

  • Description

  • Pin()

  • Adds the report to the list of reports pinned by the currently logged on user.

  • Unpin()

  • Removes the report from the list of reports pinned by the currently logged on user.

  • IsPinned()

  • Returns a value indicating whether the report is pinned by the currently logged on user.

Details

Pin()

Adds the report to the list of reports pinned by the currently logged on user.

void Pin(string displayName, IAdmReportArguments arguments)

Parameters

  • displayName - Specifies an optional display name of the pinned report.
  • arguments - Specifies optional arguments for generation of the pinned report.

Examples

The following code sample adds a report to the list of reports pinned by the currently logged on user.

PowerShell
[Reflection.Assembly]::LoadWithPartialName("Softerra.Adaxes.Adsi")

# Connect to the Adaxes service
$ns = New-Object "Softerra.Adaxes.Adsi.AdmNamespace"
$service = $ns.GetServiceDirectly("localhost")

# Bind to a report
$reportDN = "CN=My Report,CN=Reports,CN=Reports Root,CN=Configuration Objects,"+
    "CN=Adaxes Configuration,CN=Adaxes"
$report = $service.OpenObject("Adaxes://$reportDN", $null, $null, 0)

# Pin the report
$arguments = $null # Use default arguments specified for the report
$report.Pin("My Pinned Report", $arguments)
C#
using System;
using Softerra.Adaxes.Adsi;
using Softerra.Adaxes.Interop.Adsi.PersistentObjects;
using Softerra.Adaxes.Interop.Adsi.Reports;

class Program
{
    static void Main(string[] args)
    {
        // Connect to the Adaxes service
        AdmNamespace ns = new AdmNamespace();
        IAdmService service = ns.GetServiceDirectly("localhost");

        // Bind to a report
        const string reportDN = "CN=My Report,CN=Reports,CN=Reports Root,CN=Configuration Objects," +
                                "CN=Adaxes Configuration,CN=Adaxes";
        IAdmReport report =
            (IAdmReport)service.OpenObject("Adaxes://" + reportDN, null, null, 0);

        // Pin the report
        IAdmReportArguments arguments = null; // Use default arguments specified for the report
        report.Pin("My Pinned Report", arguments);
    }
}

Unpin()

Removes the report from the list of reports pinned by the currently logged on user.

void Unpin()

Examples

The following code sample removes a report from the list of reports pinned by the currently logged on user.

PowerShell
[Reflection.Assembly]::LoadWithPartialName("Softerra.Adaxes.Adsi")

# Connect to the Adaxes service
$ns = New-Object "Softerra.Adaxes.Adsi.AdmNamespace"
$service = $ns.GetServiceDirectly("localhost")

# Bind to a report
$reportDN = "CN=My report,CN=Reports,CN=Reports Root,CN=Configuration Objects,CN=Adaxes Configuration,CN=Adaxes"
$report = $service.OpenObject("Adaxes://$reportDN", $null, $null, 0)

# Unpin the report
$report.Unpin()
C#
using System;
using Softerra.Adaxes.Adsi;
using Softerra.Adaxes.Interop.Adsi.PersistentObjects;
using Softerra.Adaxes.Interop.Adsi.Reports;

class Program
{
    static void Main(string[] args)
    {
        // Connect to the Adaxes service
        AdmNamespace ns = new AdmNamespace();
        IAdmService service = ns.GetServiceDirectly("localhost");

        // Bind to a report
        const string reportDN = "CN=My report,CN=Reports,CN=Reports Root," +
                                "CN=Configuration Objects,CN=Adaxes Configuration,CN=Adaxes";
        IAdmReportPinning report =
            (IAdmReportPinning)service.OpenObject("Adaxes://" + reportDN, null, null, 0);

        // Unpin the report
        report.Unpin();
    }
}

IsPinned()

Returns a value indicating whether the report is pinned by the currently logged on user.

bool IsPinned()

Requirements

Minimum required version: 2018.1

See also