01-14-2022 12:19 PM - last edited on 05-24-2023 12:17 PM by JackLacava
My dept wants the ability to search data across region, district, and branches. I was wondering what would be the best way to build that functionality.
Currently, I have build a Select Region Parameter, which has a BR rule running these cases (member filters). And it only shows region level data.
This is how our report looks like. (Data is omitted)
However, I'm looking add an option to select districts and branches, Maybe the QV can have a button to add additional rows, by clicking "+" and selecting those specific branches from a dialog box. Or maybe a dialog box, which prompts the user to build their own entity member filter. Hope that gives an idea of where I'm heading.
Any suggestions or ideas will be appreciated. Thank you!
01-14-2022 02:57 PM - edited 01-14-2022 02:57 PM
Just an update:
I created a member dialog parameter, that let's you select a entity one at time. But I would like if if I could add more filters in, such as selecting one region, a specific parent branch (rollup) underneath it.
As shown below, it just throws everything under North Central Central (because I have use Tree Inclusive expansion). But wondering if there is a clean way to do this?
01-17-2022 11:09 AM
You could use a dashboard with either a multi-select list box or multi-select Combobox to let the users select multiple entities.
01-18-2022 11:58 AM
I tried setting up a combo box. I'm a bit lost on this. Would you please share any examples that might be out there?
01-18-2022 02:16 PM
I wrote a blog post on this a while back. However, that was a while ago when Multi-Select was not a thing.
Multi-Member selection in Cube View - CPM Insights
Now for this one, create an XFBR and call it in place for Entity. XFBR(YourRule, GetMemberSelection, DimType=Entity,Members=[|!yourentityparam!|])
Private Function GetMemberSelection(ByVal si As SessionInfo, ByVal globals As BRGlobals, ByVal args As DashboardStringFunctionArgs) As String
Try
Dim strMbrs As String = args.NameValuePairs.XFGetValue("Members")
Dim strDimType As String = args.NameValuePairs.XFGetValue("DimType")
Dim retValue As String = ""
If Not String.IsNullOrEmpty(strMbrs)
Dim mbrList As List(Of String) = strMbrs.Split(",").Select(Function(x) x.Trim).toList()
retValue = $"E#{String.Join(", E#", mbrList)}"
Else
If strDimType.StartsWith("E")
retValue = "E#None"
End If
End If
Return retValue
Catch ex As Exception
Throw ErrorHandler.LogWrite(si, New XFException(si, ex))
End Try
End Function
I'll try to create a follow-up to the previous post, hopefully by this weekend.