crystal reports viewers, crystal reports schedulers, view crystal reports, report analyzers, burst reporting, report scheduler
 
view crystal reports, rpt viewer, crystal reports viewers, crystal reports schedulers, report analyzers, burst reporting, report scheduler
desktop viewer, crystal reports viewers, crystal reports schedulers, report analyzers, burst reporting, report scheduler

Crystal Reports Tools: Improve Performance While Saving Time and Money

  Resources  
Best sellers:
cView
Report Analyzer
cViewSERVER
ReCrystallize
 


Articles:
Administration
Advanced
Basic
Crystal eNL
Database
Financial
Problems Solved

Books:
CR Books

Database Books
Developer Books

 
Tools:
Analyzers
Bestsellers

CR Schedulers
CR UFLs
CR Viewers
DataBase Tools
Graphics
International
Mail UFLs
ReCrystallizePro


Add'l:

About us

Contact Us
cViewSUITE Ppt
Support

 

CrystalReports
on Steroids

Crystal Reports: Send multiple exports from a Crystal Report

One of our local clients asked how they could do this and we had the solution already at hand. They had a report grouped by a region and wanted each region to get a CSV file with the data for that region.

One solution was to use a parameter to select the region for the report and manually export the report for each region. This would be fine for up to 5 or even 10 values for the parameter, but would be tedious if there were hundreds of values.

Another approach was to use the multirun feature of our cViewMANAGER and cViewSERVER report schedulers to run the report for each region and destination.

The solution we selected was to use our Grid User Function Library to build a grid file for each group and then save that to a region-specific CSV file. Just viewing the report generated the files. The Grid UFL had additional formatting options and could calculate columns from the data without needing to display them on the printed page.

User Function Libraries are installed on the machine running the report and accessed in the Formula Editor.

Grid UFL provides you the proper control of your Crystal Reports Export. The ability to export your reports to another application or format is one of the really useful features of Crystal Reports. But when you do this, you run into the limitations of both Crystal Reports and the other application. Grid UFL helps you overcome those limitations.
A really useful UFL:

Grid UFL allows you to treat your saved data as a Grid. To do this, you use the GridCellClear (rows,cols) to declare a work area of a predetermined size. This formula should normally be in your report header section. Then use other formulas in your group and details section to save values in the grid.

You can use GridCellLoadRawValue (row, col, value) to store a value in the working area. You could also use GridCellLoadDelimitedValue(row, col, value, delimiter) to automatically put quote marks or some other field delimiter around the value.

You can save it all to the disk file with GridCellSave(Filename,Separator). Use a comma, tab character or any other ASCII value to separate each value on each line of your disk file.

The Grid UFL processes as the report is processing. This means you could use the GridCellClear in a Group header section, and the GridCellSave in the matching Group Footer to created a different file for each group value. Just watch out for those Repeating Group Header sections or you will find your grid work area resetting on as each group repeats on a new page.

The free trial version has a limit of 20 rows and 20 columns in the output file so you can see how it works, but the full version has no restriction. This UFL is compatible with all versions of Crystal Reports (later than the very old version 5).

You get these benefits:

  • Improved performance. The Grid UFL is processed within the formulas when the report is viewed. No additional processing is needed. You just view the report and the export file(s).

  • Improved data flexibility. Some Crystal Reports are designed to extract parts of your corporate data, perform sophisticated filtering, sorting, calculations, and summaries--and then export the data as a CSV (or similar) list of values to use in another process in your system.

  • But then when you export using the native Crystal Reports options, you find a field format is not what you expect or the line has a limit on how many values you can export.

  • Increased control. With the Grid UFL, you decide the size of a grid work area and then load each cell with the value and format you want. Then at the end of the report, you save it as an external file using the delimiters you want.

  • Support for legacy reports. Crystal Reports has been around for a long time, and many older versions are still happily being used in legacy applications. The Grid UFL will install and work with any reports designed with Crystal Reports 5 and later.

 

This article is copyrighted by Crystalkeen, Mindconnection, and Chelsea Technologies Ltd. It may be freely copied and distributed as long as the original copyright is displayed and no modifications are made to this material. Extracts are permitted. The names Crystal Reports and Seagate Info are trademarks owned by Business Objects.