Question:
I'm writing a web template that has a dropdown box to switch a table from currency type 20 (group currency, the default) to currency type 10 (local currency). The dropdown box works, but I'd like the option selected to stay displayed after the screen refreshes.
For example, a user would run the template to see data in group currency by default. They would pull down the "Currency Type" menu and select "Local" to change the display to local currency. When the user does this, the table is updated to display data in local currency, but the dropdown box resets to "Currency Type".
I've done this before with other dropdown boxes (using SAPBWGetDataProviderDimensions to check properties of characteristics) but I didn't see anything in the HTML source to indicate which value for the Currency Type variable is currently selected.
Any ideas?
The code for the dropdown box is below, if anyone is interested.
<select size="1" name="currfilter" OnChange="location.href=this.options[selectedIndex].value">
<option selected value="#">Currency Type</option>
<option value="<SAP_BW_URL DATA_PROVIDER='DP_FIN' CMD='PROCESS_VARIABLES' SUBCMD='VAR_SUBMIT' VAR_NAME_1='0P_CURRT0001' VAR_VALUE_EXT_1='20'>">Group</option>
<option value="<SAP_BW_URL DATA_PROVIDER='DP_FIN' CMD='PROCESS_VARIABLES' SUBCMD='VAR_SUBMIT' VAR_NAME_1='0P_CURRT0001' VAR_VALUE_EXT_1='10'>">Local</option>
</select>
Answer:
Jason thats the problem
even i am facing the same thing in one of the scenarios...
What I feel at this stage is that the parameters set during one refresh are not retained as there is no explicit user session management in web application. All the session management is done by ICF and we are not able to put the parameters in inthe current session and genertae the page dynamically just like we can do in java technology(using session object)
Thanks
Shikher
Answer:
I don't intend on using parameters to set the status of the dropdown menu...that solution wouldn't work if a user creates a bookmark or personalizes the web template after they make the selection, because the parameter isn't stored with the bookmark URL.
The method of using built-in JavaScript functionality to check the properties of a dataprovider would be more reliable. The problem is there doesn't seem to be any way to return the value of a filter or variable.