Normally, to let user know that what are the selected values in dashboard prompt, we use narrative views or Filter views.
In this blog entry, you will see that how to use presentation variable in directly narrative view and in dashboard objects.
Recently, I had a requirement like prompt is populated with some values along with All Choices
When user selects a particular value from drop-down that value should be displayed on report and when select All Choices nothing to be display.
Variables in Narrative View:
For this i went with the following approach.
1. Create a prompt with presentation variable say, var_region and set Default to: All Choices. Save the prompt
2. Create a report with some measures and the dimension column i used as prompt in the step 1
3. Click on Results tab, and add the narrative view to compound layout
4. In Narrative section mention the presentation variable name directly @{var_region}, set Rows to display to 1 andclick OK to add the narrative to compound layout
5. Arrange views, so that the narrative view comes under the title view
6. Go to Criteria tab
7. Apply filter condition on that dimension and assign presentation variable to the filter. Save the report
8. Now create a dashboard page and add the prompt and report just now you created
9. Save the page and you can see that there nothing appears in narrative view as default value for prompt is All Choices.
10. Select any value from prompt and click on Go. You will see the selected item in report.
Note: If you are writing any text in narrative view like, Region is:@{var_region}, then even for all choices the text will be shown but no value shown for prompt
So, when there All choices option is selected in prompt associated with presentation variable, it holds nothing. It holds the value when there is single value selected. Of course, variables contains only single value
Variables in Dashboard Object – Text
- Edit the dashboard page.
- Add the Text dashboard object to the existing section
3. Click on Properties option for Text object and write the following code.
<center><font Size=’4′><font color=”#000000″>@{var_region}</font></font></center>
Don’t forget to click on Contains HTML Markup check box
4. Click on Properties of Report > Show View and select Table1 to show only the table view on dashboard, so that the narrative we are not showing. This avoids the displaying prompt values twice
5. Save the page and go to dashboard. As default value is All Choices, you will not see anything on dashboard related to text object
6. Select any value from drop-down and click on Go, and watch that the selected item is appears on dashboard
Normally, this post explains how to use presentation variables directly in views or text dashboard object and displaying prompt values in report.
ADVERTISEMENT
Hi, Is there a way to show the "Is Prompted" value in the title or use in the conditional filter? thanks.
ReplyDelete