I have looked everywhere but cannot find a method to use {CurrentDay -1}for example as the "Last Date" property on a Report Studio Date Prompt.It requires a hard coded date in date format. any pointers on this?
The only way to do this is to use Javascript on your prompt page.
If you have access to the Cognos KnowledgeBase you should search there for some samples. Be aware of that the Javascript prompting toolkit has changed between 8.2 and 8.3 so any sample scripts for 8.2 won't work in 8.3/8.4 and the other way round.
You might want to take a look at those KB articles:
KB 1019263 - Javascript: How to change the default value in date & time prompts
KB 1039556 - Dynamic default date for a date prompt
KB 1041912 - Javascript: Get the default value for a prompt from a database table.
Thanks -
I am actually not looking to set the default value or default date, but rather limiting the 'Last Day' option so the calendar itself only goes until say the end of the year, no further.
This is different from the default day which is the shadow on the prompt itself
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.