Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Parameter as Month Range

Status
Not open for further replies.

mathew001

Programmer
Jun 28, 2002
25
US
I need to create parameters in a report in such a way it is a month range...
The user select month values from say JAN 2004 to June 2004. The maximum range of months that can be selected is 12 months. How can this be acheived ?

I do not have a 'month' field in the database, but I have a date field.
The data is filtered by this date range.

Any inputs !

Thanks !
 
Set up a parameter with a min of 1 and a max of 12. do you know how to setup the perameters?
 
Do you want Crystal to prompt for a start date and then just include 12 months from that date? Or is this really a month-driven parameter?

Software Sales, Training, Implementation and Support for Exact Macola, eSynergy, and Crystal Reports
askdon@srhconsulting.com
 
hneal98, I know how to create parameters. But in this case, are we giving the options 1 - 12 for the users ???

dgillz, we do not need Crystal to prompt for a start date and select previous 12 months. It should be month driven - The parametrs should ne like Dec 03,Jan 04, Feb 04 etc and the range should not be more than 12 months.

I am using Crystal report 10
 
Do one parameter for starting month and year, and another for number of months till the end date.

Use Date (year-value, month-value, day-value) to turn the starting month and year into the first of that month.

Use DateAdd ("m", month-param, {your.date}) to get the end date.

You can also use ToText(Start-date, "MMM yy") to display the dates.

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top