Returns the text stored in the UserDefined1 attribute of a Scenario dimension member.
<HsvScenarios>.GetUserDefined1 lItemID, pbstrUserDefined
This example tests whether the UserDefined1 attribute of a Scenario dimension member consists of the letter Y. The Scenario dimension member’s label is specified in a combo box named comboCat. GetItemID returns this member’s ID, which is then passed to GetUserDefined1. If GetUserDefined1 returns the letter Y, then any code placed within the If structure would be executed.
Dim cScenarios As HsvScenarios, cTreeInfo As IHsvTreeInfo
Dim lScen As Long, sCatLabel As String, sUser As String
Set cScenarios = m_cMetadata.Scenarios
Set cTreeInfo = m_cMetadata.Scenarios
sCatLabel = comboCat.Text
lScen = cTreeInfo.GetItemID(sCatLabel)
cScenarios.GetUserDefined1 lScen, sUser
If Trim(sUser) = "Y" Then
…
End If