ICompoundDimensionInstance.Type

Fore Syntax

Type: DimCompoundDimensionType;

Fore.NET Syntax

Type: Prognoz.Platform.Interop.Dimensions.DimCompoundDimensionType;

Description

The Type property returns type of composite dimension.

Comments

The property is read-only.

Fore Example

Executing the example requires that repository contains virtual cube with the VIRT_CUBE identifier.

Add links to the Cubes, Dimensions, Metabase system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    Cube: IVirtualCube;
    CDim: ICompoundDimension;
    Params: IMetabaseObjectParamValues;
    CDimInst: ICompoundDimensionInstance;
Begin
    // Get repository
    MB := MetabaseClass.Active;
    // Get virtual cube
    Cube := MB.ItemById("VIRT_CUBE").Edit As IVirtualCube;
    // Get data of composite dimension
    CDim := Cube.FactDimension As ICompoundDimension;
    Params := (CDim As IMetabaseObject).Params.CreateEmptyValues;
    CDimInst := (CDim As IMetabaseObject).Open(Params) As ICompoundDimensionInstance;
    Select Case (CDimInst.Type As Integer)
        Case 1: Debug.WriteLine("Type of composite dimension - regular");
        Case 2: Debug.WriteLine("Type of composite dimension - metahierarchy");
    End Select;
End Sub UserProc;

After executing the example the console displays type of virtual cube composite dimension.

Fore.NET Example

The requirements and result of the Fore.NET example execution match with those in the Fore Example.

Imports Prognoz.Platform.Interop.Cubes;
Imports Prognoz.Platform.Interop.Dimensions;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    Cube: IVirtualCube;
    CDim: ICompoundDimension;
    Paramss: IMetabaseObjectParamValues;
    CDimInst: ICompoundDimensionInstance;
Begin
    // Get repository
    MB := Params.Metabase;
    // Get virtual cube
    Cube := MB.ItemById["VIRT_CUBE"].Edit() As IVirtualCube;
    // Get data of composite dimension
    CDim := Cube.FactDimension As ICompoundDimension;
    Paramss := (CDim As IMetabaseObject).Params.CreateEmptyValues();
    CDimInst := (CDim As IMetabaseObject).Open(Paramss) As ICompoundDimensionInstance;
    Select Case (CDimInst.Type As Integer)
        Case 1: System.Diagnostics.Debug.WriteLine("Type of composite dimension - regular");
        Case 2: System.Diagnostics.Debug.WriteLine("Type of composite dimension - metahierarchy");
    End Select;
End Sub;

See also:

ICompoundDimensionInstance