Hi All,
Is it possible to create an array of ararys in crystal reports?
I need to keep track of some daily and weekly total for a number of months Here's the deal:
A web user (which interacts with a .NET application, not with the report itself) will request to view a report and will provide a range of dates (e.g. Jan1 - Jan 23) to include in it.
My report will look something like this:
[tt] Januaray
week 1 week 2 week 3 week 4
no % no % no % no %
Item 1 -- - -- - -- - -- -
Item 2 -- - -- - -- - -- -
Item 3 -- - -- - -- - -- -
Item 4 -- - -- - -- - -- -
Item 5 -- - -- - -- - -- -
Item 6 -- - -- - -- - -- -
.
.
.
Total -- - -- - -- - -- -[/tt]
Each week displays an average. Due to the fact that some weeks are shorter than others (e.g. for a mon-fri week, if the first of the month is on a thursday, that week will only have 2 days in it), the number of days in the week may vary, and thus I need to calculate the number of days in each week to compute the average correctly. Many of my records may have the same date and so, to calculate the number of unique days in each week, I keep an array of the unique days found per week. Something like this:
[tt]
if not ({myTable.Date} in arrayDatesInWeek1) then
// increment the number of days in this week
// add the current date to the array[/tt]
To implement the above without array of arrays, I'll be forced create five arrays (one for each week).
Thus, the question: Is it possible to create an array of arrays in Crystal Reports? If so, how?
Thanks!
JC
_________________________________________________
To get the best response to a question, read faq222-2244.
Is it possible to create an array of ararys in crystal reports?
I need to keep track of some daily and weekly total for a number of months Here's the deal:
A web user (which interacts with a .NET application, not with the report itself) will request to view a report and will provide a range of dates (e.g. Jan1 - Jan 23) to include in it.
My report will look something like this:
[tt] Januaray
week 1 week 2 week 3 week 4
no % no % no % no %
Item 1 -- - -- - -- - -- -
Item 2 -- - -- - -- - -- -
Item 3 -- - -- - -- - -- -
Item 4 -- - -- - -- - -- -
Item 5 -- - -- - -- - -- -
Item 6 -- - -- - -- - -- -
.
.
.
Total -- - -- - -- - -- -[/tt]
Each week displays an average. Due to the fact that some weeks are shorter than others (e.g. for a mon-fri week, if the first of the month is on a thursday, that week will only have 2 days in it), the number of days in the week may vary, and thus I need to calculate the number of days in each week to compute the average correctly. Many of my records may have the same date and so, to calculate the number of unique days in each week, I keep an array of the unique days found per week. Something like this:
[tt]
if not ({myTable.Date} in arrayDatesInWeek1) then
// increment the number of days in this week
// add the current date to the array[/tt]
To implement the above without array of arrays, I'll be forced create five arrays (one for each week).
Thus, the question: Is it possible to create an array of arrays in Crystal Reports? If so, how?
Thanks!
JC
_________________________________________________
To get the best response to a question, read faq222-2244.