Show the current time filter on a report

How can I show the current time filtering on a dashboard title?

I added a datalabel on the report title, you can see the current time, however it depends on the hierarchy level choosed for that datalabel, but if you have a time dimensions with, e.g. 3 levels: year-month-day, how can I show the correct filter value?

Thanks,

Luis Silva

Are you looking to add the run time of the report? Like a time stamp for exporting?

If I have a report where the time dimension is used as a slicer, I want to be able to see when I share, for example the report as a pdf, the value of the filter that was applied to that report.

Thanks,

Nothing like an example:

In the above image I applied a time dimension filtered, I want to show on the report header the time selected, in this case is “maio, 2018”, is there a way to show this?

Hi Luis,

There are probably multiple options here but the quickest to me would be to add a label to your report/dashboard and script the value based on the selection of the parameter control.

Something like this:
On the Value Change Interaction of the filter control

// update the label’s text based on the selected value
label1.labelText = parameterCalendar1.control.parameterValue.value.memberTime;

Hi Luis,

Script is of course always an option but if I understand your case correctly it isn’t necessary. The Labels window (normally docked on the right) will list each parameter you already added to your parameters bar, and you can drag one of these onto the report header, for example, to create that label. Alternatively, if you edit an existing label’s Text property you’ll find a popup listing each parameter along with the other meta-data you can display. (It can be helpful to give each parameter a descriptive name in the Parameters window first.)

You can find more here: https://www.dundas.com/support/learning/documentation/create-view-content/design-tips-for-reports-and-scorecards#h3-include-metadata

Hi Jeff,

I’ve tried your script, but it didn’t work for me. I have a label with scriptname “label1” and also a calendar filter with scriptname “parameterCalendar1”, however when I change the filter value, I got an error on browser console, saying that parameterCalendar1 doesn’t exist! See image bellow:

Thanks,

Luis

Hi Jamie,

Your solutions works some way, however if I use a token value, what I get is “previous year”, which won’t tell much for the someone who receives the report, is there a workaround?

Thanks,

Luis

Hi Jeff,

Just to mention that your script works on a dashboard, but not on a report!

Luis

Hi Luis,

Apologies - my goal was just to give you a rough sample. On the report it’s a little different as the parameter object is not directly usable in the script. Instead you simply have to call “this.”.

titleLabel.labelText = this.control.parameterValue.value.memberTime;