IBindingDimCombo.DisplayUserListAttr

Syntax

DisplayUserListAttr: String;

Description

The DisplayUserListAttr property determines value of the DISPLAYUSERLISTATTR parameter in the binding string.

Comments

The DISPLAYUSERLISTATTR parameter determines a custom template that will be used to create names of elements of all levels in the expanded editor. Parameter value is a string that can contain any text and attribute substitutions. The attribute substitution looks as follows: %Attribute identifier%. The attributes, for which openness attribute is not set, are available for use. The example:

DISPLAYUSERLISTATTR = "Name: %NAME% (Date: %USER_DATE_ATTR%)"

In the Value Editor Parameters dialog box value of this parameter is set using the Custom Name of All Levels parameter.

Example

Executing the example requires that the repository contains a regular report with the REGULAR_REPORT identifier and a dictionary with the DIMENSIONS identifier.

Add links to the Metabase, Report and Tab system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    Report: IPrxReport;
    BM: IBindingManager;
    DimComboBinding: IBindingDimCombo;
    Tab: ITabSheet;
    Style: ITabCellStyle;
    Binding: IBindingValue;
Begin
    // Get the current repository
    MB := MetabaseClass.Active;
    // Get regular report
    Report := MB.ItemById("REGULAR_REPORT").Edit As IPrxReport;
    // Get cell style in upper left corner of active report sheet
    Tab := (Report.ActiveSheet As IPrxTable).TabSheet;
    Style := Tab.Cell(00).Style;
    // Create and set up value editor as a drop-down list
    BM := New BindingManager.Create;
    Binding := BM.CreateByUi("DimCombo");
    DimComboBinding := Binding As IBindingDimCombo;
    DimComboBinding.Object := "DIMENSIONS";
    DimComboBinding.DisplayUserListAttr := "%NAME%";
    Style.Binding := DimComboBinding.AsString;
    // Save changes
    (Report As IMetabaseObject).Save;
End Sub UserProc;

After executing the example the value editor is set for the A0 cell in regular report as a dictionary drop-down list with the %NAME% custom name of all dictionary levels.

See also:

IBindingDimCombo