EsbOtlSetMemberAlias() sets the default member alias for a specified member in a specified alias table.
EsbOtlSetMemberAlias (hOutline, hMember, pszAliasTable, pszAlias)
ByVal hOutline As Long ByVal hMember As Long ByVal pszAliasTable As String ByVal pszAlias As String
| hOutline | Outline context handle. |
| hMember | Handle of member to set the alias for. |
| pszAliasTable | Alias table to set the alias for. If this parameter is "", the default alias table is used. |
| pszAlias | Alias. |
Returns 0 if successful; otherwise one of the following:
OTLAPI_BAD_ALIASTABLE
OTLAPI_ERR_ALIASSHARED
OTLAPI_ERR_ILLEGALDEFALIAS
OTLAPI_ERR_ILLEGALCOMBOALIAS
OTLAPI_ERR_ILLEGALALIASSTRING
OTLAPI_ERR_DUPLICATEALIAS
Declare Function EsbOtlSetMemberAlias Lib
"ESBOTLW" (ByVal hOutline As Long, ByVal hMember As Long,
ByVal pszAliasTable As String, ByVal pszAlias As String) As Long
Sub ESB_OtlSetMemberAlias()
Dim sts As Long
Dim Object As ESB_OBJDEF_T
Dim hOutline As Long
Dim hMemberYear As Long
Dim szAlias As String * ESB_MBRNAMELEN
Object.hCtx = hCtx
Object.Type = ESB_OBJTYPE_OUTLINE
Object.AppName = "Sample"
Object.DbName = "Basic"
Object.FileName = "Basic"
sts = EsbOtlOpenOutline(hCtx, Object,
SB_YES, ESB_YES, hOutline)
If sts = 0 Then
sts = EsbOtlFindMember(hOutline, "Year",
hMemberYear)
End If
If sts = 0 And hMemberYear <> 0 Then
szAlias = "Year Dimension"
sts = EsbOtlSetMemberAlias(hOutline,
hMemberYear, "", szAlias)
End If
End Sub