COGNOiSe.com - The IBM Cognos Community

Legacy Business Intelligence => COGNOS ReportNet => Topic started by: Desperado on 09 Apr 2006 11:42:15 PM

Title: Javascript help required for date range radio button prompt
Post by: Desperado on 09 Apr 2006 11:42:15 PM
Hi,

I have to create a radio button prompt which will have three values
1. last full month
2. Year to date
3. other

1. should retrieve the last complete month ie, from 1 Mar to 31 Mar (if the user selects this)
2. should retrieve the year to date ie, from 1 Jan to current date
3. other means the user can select his own date range.

I already have the code for the date range. Can some one help me with the javascript for 1 &2.
Thanks in Advance
Title: Re: Javascript help required for date range radio button prompt
Post by: sir_jeroen on 13 Apr 2006 04:35:15 PM
Why don't you post the code.. We're not gonna write it for you.... :P
Title: Re: Javascript help required for date range radio button prompt
Post by: bdybldr on 14 Apr 2006 09:19:32 AM
Desperado,
Why do you have to use JavaScript?  You can just add a value prompt and change the Select UI to "Radio button group".  Then populate it with static choices for the three options.
Title: Re: Javascript help required for date range radio button prompt
Post by: Desperado on 26 Apr 2006 04:29:22 AM
bdybldr,
How can i just use only a radio button group ? i'm using a radio button group for the value prompt.. but if i select last full month, where should it get the values from ?? I worked it out with a filter, But i don't want the filter to do it... I want the java script to be used as it reduces query time..

In my first posting i mentioned that i have the coding only for the DATE RANGE.. i don't know why Reportnet Addict is asking for the code which i don't have...Is he gone Nuts... ???  ???if i have the code i shouldn't have posted it first thing ...
Title: Re: Javascript help required for date range radio button prompt
Post by: sir_jeroen on 29 Apr 2006 06:57:30 PM
Desperado..
You wrote:
QuoteCan some one help me with the javascript for 1 &2
This is like saying I can't figure it out, I already got some code but it's not working properly. Help me solve it..
But apperently you want others to do your own work.
Next time change the title for the topic to: Can some one GIVE me the javascript for 1 &2.. because I'm lazy