# EsbOtlSetAttributeSpecifications

Description

EsbOtlSetAttributeSpecifications() sets attribute specifications for the outline.

Syntax

    EsbOtlSetAttributeSpecifications (hOutline, AttrSpecs)

    ByVal hOutline  As Long
          AttrSpecs As ESB_ATTRSPECS_T

Parameters

hOutline | Handle to the outline
AttrSpecs | Attribute specifications

Return Value

Notes

- Attribute specifications are used to do the following:
  - Generate a long name
  - Indicate the format of a datetime attribute
  - Indicate a numeric attribute's bucketing type
  - Provide the name of the attribute calculations dimension and the names for the values used with it
- If you do not set attribute specifications, the outline uses the default attribute specifications.
- Changing attribute specifications may cause a restructure.

Access

This function requires no special privileges.

Example

    Sub ESB_OtlSetAttributeSpecifications()
         Dim InAttrSpecs As ESB_ATTRSPECS_T

         eraser
         InAttrSpecs.GenNameBy = InputBox("Enter GenNameBy:" & vbCrLf & _
              "0. ESB_GENNAMEBY_PREFIX" & vbCrLf & _
              "1. ESB_GENNAMEBY_SUFFIX")
         InAttrSpecs.UseNameOf = InputBox("Enter UseNameOf:" & vbCrLf & _
              "0. ESB_USENAMEOF_NONE" & vbCrLf & _
              "1. ESB_USENAMEOF_PARENT" & vbCrLf & _
              "2. ESB_USENAMEOF_GRANDPARENTANDPARENT" & vbCrLf & _
              "3. ESB_USENAMEOF_ALLANCESTORS" & vbCrLf & _
              "4. ESB_USENAMEOF_DIMENSION")
         InAttrSpecs.Delimiter = InputBox("Enter Delimiter:" & vbCrLf & _
              "0. ESB_DELIMITER_UNDERSCORE" & vbCrLf & _
              "1. ESB_DELIMITER_PIPE" & vbCrLf & _
              "2. ESB_DELIMITER_CARET")
         InAttrSpecs.DateFormat = InputBox("Enter DateFormat:" & vbCrLf & _
              "0. ESB_DATEFORMAT_MMDDYYYY" & vbCrLf & _
              "1. ESB_DATEFORMAT_DDMMYYYY")
         InAttrSpecs.BucketingType = InputBox("Enter BucketingType:" & vbCrLf & _
              "0. ESB_UPPERBOUNDINCLUSIVE" & vbCrLf & _
              "1. ESB_ESB_LOWERBOUNDINCLUSIVE" & vbCrLf & _
              "2. ESB_UPPERBOUNDNONINCLUSIVE" & vbCrLf & _
              "3. ESB_ESB_LOWERBOUNDNONINCLUSIVE")

         InAttrSpecs.DefaultTrueString = InputBox("Enter DefaultTrueString: ", , "ESB_DEFAULT_TRUESTRING")
         InAttrSpecs.DefaultFalseString = InputBox("Enter DefaultFalseString: ", , "ESB_DEFAULT_FALSESTRING")
         InAttrSpecs.DefaultAttrCalcDimName = InputBox("Enter DefaultAttrCalcDimName: ", , "ESB_DEFAULT_ATTRIBUTECALCULATIONS")
         InAttrSpecs.DefaultSumMbrName = InputBox("Enter DefaultSumMbrName: ", , "ESB_DEFAULT_SUM")
         InAttrSpecs.DefaultCountMbrName = InputBox("Enter DefaultCountMbrName: ", , "ESB_DEFAULT_COUNT")
         InAttrSpecs.DefaultAverageMbrName = InputBox("Enter DefaultAverageMbrName: ", , "ESB_DEFAULT_AVERAGE")
         InAttrSpecs.DefaultMinMbrName = InputBox("Enter DefaultMinMbrName: ", , "ESB_DEFAULT_MIN")
         InAttrSpecs.DefaultMaxMbrName = InputBox("Enter DefaultMaxMbrName: ", , "ESB_DEFAULT_MAX")

         sts = EsbOtlSetAttributeSpecifications(ghOutline, InAttrSpecs)

         If sts = 0 Then
              Out "ESB_OtlSetAttributeSpecifications passed: " & sts
              Out "GenNameBy : " & InAttrSpecs.GenNameBy
              Out "UseNameOf : " & InAttrSpecs.UseNameOf
              Out "Delimiter : " & InAttrSpecs.Delimiter
              Out "DateFormat : " & InAttrSpecs.DateFormat
              Out "BucketingType : " & InAttrSpecs.BucketingType
              Out "DefaultTrueString : " & InAttrSpecs.DefaultTrueString
              Out "DefaultFalseString : " & InAttrSpecs.DefaultFalseString
              Out "DefaultAttrCalcDimName : " & InAttrSpecs.DefaultAttrCalcDimName
              Out "DefaultSumMbrName : " & InAttrSpecs.DefaultSumMbrName
              Out "DefaultCountMbrName : " & InAttrSpecs.DefaultCountMbrName
              Out "DefaultAverageMbrName : " & InAttrSpecs.DefaultAverageMbrName
              Out "DefaultMinMbrName : " & InAttrSpecs.DefaultMinMbrName
              Out "DefaultMaxMbrName : " & InAttrSpecs.DefaultMaxMbrName
         Else
              Out "ESB_OtlSetAttributeSpecifications failed" & sts
              Exit Sub
         End If
    End Sub

See Also

EsbCheckAttributes()
EsbGetAssociatedAttributesInfo()
EsbGetAttributeInfo()
EsbGetAttributeSpecifications()
EsbOtlAssociateAttributeDimension()
EsbOtlAssociateAttributeMember()
EsbOtlDisassociateAttributeDimension()
EsbOtlDisassociateAttributeMember()
EsbOtlFindAttributeMembers()
EsbOtlGetAssociatedAttributes()
EsbOtlGetAttributeInfo()
EsbOtlGetAttributeSpecifications()
EsbOtlQueryAttributes()