Changing the title of the value prompt
In the previous example, the first line of the value prompt shows the data item name, that is, Month key (ship date) as shown in the following screenshot:
The business owners want to change this to a more generic and user-friendly text.
Getting ready
We will use the report generated in the previous recipe.
How to do it...
We need to add a line to the JavaScript from the previous recipe to change the text of first option (index 0). To do this perform the following steps:
Open the prompt page of the report created in the previous recipe.
Double-click on the HTML item that contains the JavaScript.
Replace the code with the following:
<script> var theSpan = document.getElementById("A1"); var a = theSpan.getElementsByTagName("select"); for( var i = a.length-1; i >= 0; i-- ) { var prompts = a[i]; if( prompts.id.match(/PRMT_SV_/)) { prompts.selectedIndex = 3; prompts.options[0].text = 'Choose Shipment Month'; /* This is the new line added to script...