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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Auto generating parameters for recurring reports

Status
Not open for further replies.

BrettS

Programmer
Jan 7, 2002
12
US
I have a Crystal report published on Enterprise. The report itself does not need parameters, but I include what I call a "Display Parameter". The purpose of this parameter is to show what Month and Year the report is for when the report is a historical instance (not the latest instance) on the CMC history.

For example, each month I run the Balance Sheet report for the prior month. In March it would be for the "FEB, 2009" data. Then, say a few months later, a user wants to look at that report instance they can look at the historical instances and find the one with the parameter "FEB, 2009".

Right now I have about a 100 reports like this and I have to schedule each occurrence and manually set the "Display Parameter" for each month for each report. Is there a way to programmatically generate this parameter in the CMC or elsewhere?

We are currently not using WEBI, DESKI, or UNIVERSES, but we may be in the future.
 
It sounds like you should add a formula to each scheduled report to display the previous month:

ToText(DateAdd ("m", -1, CurrentDate),"MMM, yyyy")
 
Thanks for the input jlewis, but the problem isn't with the report displaying the "MMM, YYYY" data (I already have that handled). The problem is getting the CMC to display the that data on the CMC's History page.
 
The one thing I can think of would be to write a program that you could run once a month that would go through and schedule all of the reports for you. You could make it data driven so that you can add and remove reports from the list as your configuration changes. You would then enter the display parameter, click a button, and it would scheduled each of them with the appropriate display parameter.

It's not that difficult to do and I have C# sample code available for scheduling reports.

-Dell

A computer only does what you actually told it to do - not what you thought you told it to do.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top