FindMemberOccurrencesInHierarchy

Returns an array containing the fully qualified names of all members in a dimension hierarchy whose names match the specified search string.

Tip:

To return the names of all members that match a search string and that are descendants of a specified member, use FindMemberOccurrencesInHierarchyEx.

Syntax

<HFMwDimension>.FindMemberOccurrencesInHierarchy (bstrSearchText)

Argument

Description

bstrSearchText

The search string. Specify either a member name or a string containing a wildcard to search for a partial match. For example, "C*" searches for any member that begins with the letter C.

Input argument. String subtype.

Return Value

Returns an array containing the fully qualified names of the members that match the search criteria. In the array items, the member names in the hierarchy are delimited by backslashes. For example, suppose that an entity named Italy appears twice. FindMemberOccurrencesInHierarchy would return an array containing two items similar to the following:

Example

The following function returns the names of all Entity dimension members that match the passed search string.

Function getEntityInHierarchy(sList)
Dim cHFMMetadata, cHFMEntities, cDimension, sEntity
set cHFMMetadata = Server.CreateObject("Hyperion.HFMwMetadata")
cHFMMetadata.SetWebSession cHFMSession
Set cHFMEntities = cHFMMetadata.entities
Set cDimension = cHFMEntities.dimension
sEntity = cDimension.FindMemberOccurrencesInHierarchy(sList)
getEntityInHierarchy = sEntity
End Function