IAdhocParamSyncItem.ParamId

Syntax

ParamId: String;

Description

The ParamId property returns parameter identifier.

Comments

To set parameter value, use the IAdhocParamSyncItem.Value property.

Example

Executing the example requires that the repository contains a dashboard with the DASHBOARD_PARAMS identifier. This dashboard must contain links to synchronize parameters.

Add links to the Adhoc, Metabase system assemblies.

Sub UserProc;
Var
    mb: IMetabase;
    Dashboard: IAdhocReport;
    Sync: IAdhocSynchronization;
    ParamSync: IAdhocParamSynchronization;
    i, j: Integer;
    ParamSyncInd: IAdhocParamSyncIndex;
    SyncParams: IAdhocSyncParams;
    Param: IAdhocParamSyncItem;
    Src: IAdhocDataSourceObject;
    SrcObj: IMetabaseObject;
Begin
    // Get current repository
    mb := MetabaseClass.Active;
    // Get dashboard
    Dashboard := mb.ItemById("DASHBOARD_PARAMS").Bind As IAdhocReport;
    // Get dashboard synchronization parameters     Sync := Dashboard.Synchronization;
    // Get links to synchronize parameters
    ParamSync := Sync.Params;
    // Look over links
    For i := 0 To ParamSync.Count - 1 Do
        ParamSyncInd := ParamSync.Item(0);
        // Get parameters which included into the link
        SyncParams := ParamSyncInd.Params;
        // Look over parameters
        For j := 0 To SyncParams.Count - 1 Do
            // Get parameter and display information about it
            Param := SyncParams.Item(j);
            Debug.WriteLine("Parameter identifier: " + Param.ParamId);
            Debug.WriteLine("Parameter value: " + Param.Value);
            Src := Param.Source;
            SrcObj := Src.GetSourceObject As IMetabaseObject;
            Debug.WriteLine("Data source: " + SrcObj.Name);
            Debug.WriteLine("Link, which includes the parameter: " + Param.SyncIndex.Name);
            Debug.WriteLine("");
        End For;
    End For;
End Sub UserProc;

After executing the example the console window displays information about synchronized parameters of the dashboard.

See also:

IAdhocParamSyncItem