03-15-2023 02:52 PM - last edited on 05-02-2023 10:28 AM by JackLacava
The below finance rule will sort the members in my case it is entity and it will take the parameters in the Cube view.
'*******************************************************************************************************************
'Parameters in the Cube View
'E#Root.CustomMemberList(BRName=MemberSort, MemberListName=AscEntSort, Memlist=E#[Legal].DescendantsInclusive)
'********************************************************************************************************************
Dim Memberlistname As String = "AscEntSort"
Dim MemberListstart As String = args.MemberListArgs.NameValuePairs.XFGetValue("Memlist",Nothing)
Case Is = FinanceFunctionType.MemberList
If args.MemberListArgs.MemberListName = Memberlistname Then
Dim objMemberListHeader = New MemberListHeader(args.MemberListArgs.MemberListName)
'members into the list
Dim objMemberInfos As List(Of MemberInfo) = api.Members.GetMembersUsingFilter( _
args.MemberListArgs.DimPk, MemberListstart, Nothing)
'Sort the members with Ascending Order
Dim objMembers As List(Of Member) = Nothing
If Not objMemberInfos Is Nothing Then
objMembers = (From memberInfo In objMemberInfos _
Order By memberInfo.Member.Name Ascending _
Select memberInfo.Member).ToList()
End If
'Return
Return New MemberList(objMemberListHeader, objMembers)
End If
Solved! Go to Solution.
03-16-2023 07:20 AM - edited 03-16-2023 07:20 AM
Hey Kris,
thanks for posting your spin on the XFR_MemberListAlphabetical rule from Golfstream. You have successfully parameterized the list that is passed in; I guess the next step would be to parameterize the sorting order 😉
03-16-2023 07:20 AM - edited 03-16-2023 07:20 AM
Hey Kris,
thanks for posting your spin on the XFR_MemberListAlphabetical rule from Golfstream. You have successfully parameterized the list that is passed in; I guess the next step would be to parameterize the sorting order 😉