The OneStream Community is temporarily frozen until June 29th due to the ongoing maintenance. Please read the blog post here to learn more.
Forum Discussion
OSAdmin
OneStream Employee
5 years agoIn a dashboard based on a cube view, I am trying to bind the time period to the selection of the scenario?
Originally posted by Dominic Arblaster 12/4/2019
Also to change the column text name. Column 1 is always Actual at current rates at the pov time period. Column 2 starts as Actual at current rate...
OSAdmin
OneStream Employee
5 years ago Originally posted by Chul Smith
you can use a XFBR rule in Col2. Send the scenario parameter to the rule and return the time needed. this might fall into the category where you can't drive this via a parameter. Last thing to try would be to use |!ParamScenLastYear!|
This works, but I decided to pass the time filter in to be sure of the outcome:
If args.FunctionName.XFEqualsIgnoreCase(""ScenarioChange"") Then
Dim paramScenarioValue As String = args.NameValuePairs.XFGetValue(""ParamScenLastYear"")
Dim paramid As Integer = BRApi.Finance.Members.GetMemberId(si, 2 , paramScenarioValue)
Dim povtime As String = args.NameValuePairs.XFGetValue(""POVtimeFilter"")
Dim nowyear As Integer = TimeDimHelper.GetSubComponentsFromName(povtime).Year 'year number of current year
Dim curMonth As Integer = TimeDimHelper.GetSubComponentsFromName(povtime).Month 'Month number of current month
Dim lastyear As Integer = nowyear -1
Dim povtimey As String = lastyear & ""M"" & curMonth
If paramid = 1048578 Then ' 1048578 is the id of Scenario ""Act_Cur_Tar""
Return ""T#"" & povtimey
Else
Return ""T#"" & povtime
End If
End If
Return Nothing
Catch ex As Exception
Throw ErrorHandler.LogWrite(si, New XFException(si, ex))
The pop-up for Scenario shows the description and they are renaming metadata, so I prefer to use the ID here
Corresponding BR with extra time:
BRString( GMR_PeriodFilterForScenario, ScenarioChange, ParamScenLastYear = |!ParamScenLastYear!|, POVtimeFilter = |povtime| ):S#|!ParamScenLastYear!|
Related Content
- 5 months ago
- 2 years ago