IMetabaseDialogCombiFilter.Filters

Syntax

Filters: IMetabaseDialogFilters;

Description

The Filters property returns the filters collection of a combined filter.

Example

Executing the example requires a form with the Button1 button and the MetabaseOpenDialog component named MetabaseOpenDialog1.

    Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
    Var
        MetaclassFilter: IMetabaseDialogMetaclassFilter;
        ClassFilter: IMetabaseDialogClassFilter;
        CombiFilter: IMetabaseDialogCombiFilter;
        Filters: IMetabaseDialogFilters;
    Begin
        //Filter for all kinds of dictionaries
        MetaclassFilter := New MetabaseDialogMetaclassFilter.Create;
        MetaclassFilter.Description := "All dictionaries";
        MetaclassFilter.ObjectMetaclass := MetabaseObjectMetaclass.DIMENSION_CLASS;
        //Filter for standard cubes
        ClassFilter := New MetabaseDialogClassFilter.Create;
        ClassFilter.Description := "Standard cubes";
        ClassFilter.ObjectClass := MetabaseObjectClass.KE_CLASS_STDCUBE;
        //Combined filter
        CombiFilter := New MetabaseDialogCombiFilter.Create;
        Filters := CombiFilter.Filters;
        Filters.AddFilter(MetaclassFilter);
        Filters.AddFilter(ClassFilter);
        //Link combined filter in component
        MetabaseOpenDialog1.Filters.AddFilter(CombiFilter);
        MetabaseOpenDialog1.Execute(Self);
    End Sub Button1OnClick;

After executing the example three filters are created after clicking the button:

Combined filter is included into filter list of the MetabaseOpenDialog1 component.

See also:

IMetabaseDialogCombiFilter