LevelType

The LevelType property of the Level interface returns an enumeration constant identifying the specific type of level.

Applies To
clsAggregationLevel clsDatabaseLevel
clsCubeLevel clsPartitionLevel

Data Type

LevelTypes (an enumeration)

Access

The access type depends on the level object class.

Class Access
clsDatabaseLevel R/W
clsCubeLevel R
clsPartitionLevel R
clsAggregationLevel R

Remarks

The LevelType property may be set to one of the constants enumerated by the LevelTypes enumeration. The first level must be unique and always be of type levAll. Subsequent levels are of the type levRegular with the exception of levels in a time dimension. Time levels have their LevelType property set to one of the time level constants such as levTimeYears or levTimeMonths. Time levels must be created in time hierarchy fashion. For example, the first level in a time dimension (other than All) would have the type levTimeYears. The second, levTimeMonths, and so on. For a complete list of level types, see Enumerations.

Example

Use the following code to set a the level type of a level object to days:

LevelObject.LevelType = levTimeDays

Use the following code to return a the level type of a level object and determine which level type has been returned:

'Assume an object (dsoLevel) of ClassType clsDatabaseLevel exists

Dim objType As LevelTypes

objType = dsoLevel.LevelType

Select Case objType

  Case levRegular

    ' Commands for levRegular

  Case levAll

    ' Commands for levAll

  Case Else

    ' other commands

End Select

See Also
About Decision Support Objects Using Decision Support Objects
LevelTypes Properties Cross-Reference

(c) 1988-1998 Microsoft Corporation. All Rights Reserved.