Click here to Skip to main content
11,432,168 members (61,790 online)
Click here to Skip to main content

EasiReports

, 13 Feb 2006 CPOL
Rate this:
Please Sign up or sign in to vote.
A library to add reports to your application.

I suggest you start with the help, the binaries, and the examples. The binaries include a generic wrapper application "EasiReporter" which you can use to test EasiReports against your data sources. The examples include many reports that show the capabilities of EasiReports, including using alternative data sources.

Click for full-size image

Click for full-size image.

Introduction

EasiReports provides a reporting solution for your applications. It is a professional-quality library with comprehensive help files and examples.

EasiReports has been written to be as simple as possible to integrate into your applications and to be as simple as possible for your users. You can publish your own reports, but EasiReports is also aimed at giving your users the power to write their own reports, or modify templates that you provide.

Its unique features include:

  • Automatic SQL generation when accessing a database, so your users don’t have to know anything about SQL.
  • It is highly extensible through its “Plugins” architecture, which provides great flexibility in any .NET language.
  • It can use any .NET data source as input.
  • It can output to many graphics file formats in addition to printing and print preview.

EasiReports follows the section paradigm familiar to Access users, so the learning curve is kept to a minimum. Common tasks can be performed easily, while more complex features are available for advanced users. These include writing code for the integrated C# and VB compilers and even referencing CLR assemblies written in any .NET language.

A demo application, EasiReporter, is included in the SDK. You can use this to explore the capabilities of EasiReports and to test against your own databases or other data sources. It is also useful as a generic report editor for writing your own reports.

In this article, I will briefly describe the main features available in EasiReports. For more detailed information, see the help files. In particular, there is a "Walkthrough" describing how to include EasiReports in your application, in the EasiReports section of the help file.

License

You may use EasiReports in your applications for free. You may not use it in comparable or competitive products. See the license file for details.

You may use the following license key in your applications:

"BuiltNicer;4;CodeProject;71502708;4780EB20"

Background

Reporting is often required in applications but is not as easy as it seems. EasiReports provides a generic reporting solution for accessing any .NET data source.

EasiReports has been written to solve a common requirement and is not just for database applications -- it is flexible enough to be used in many scenarios. For instance, if you just want to preview and print standard reports, you do not have to make the report designer available to the end-user.

In my experience, managers under-value reporting in an application and under-estimate the effort required to provide a stable and comprehensive solution. With EasiReports, you can quickly and simply solve this problem.

Features

User report designer

The user report designer is built into the heart of EasiReports. Include this control in your application to allow users to create, edit, preview, and print their own reports, or to modify templates that you provide. This is part of the core functionality of EasiReports and has been made as simple as possible.

No SQL coding required

Users don't have to know anything about SQL -- EasiReports interrogates your database for metadata, and builds dynamic SQL on the fly. It does this by collecting metadata about the tables, fields, primary and foreign keys in your database. It then examines the report to find out which tables and fields are referenced, and it builds a SQL statement, complete with table joins, which returns all the required data. Use EasiReports for this reason alone!

Data Sources

EasiReports uses OLEDB for default database access but all common .NET data sources are directly supported. If your data source is not supported, it is quite simple to write your own data source handler to expose your data.

Output

In addition to print and print preview, you can also export to many graphics file formats such as GIF, JPEG, and PNG, with just one line of code.

Source Code

Full source code is included with EasiReports. This includes the main source, and the code for three assemblies to give you practical examples of using EasiReports. These are:

  • EasiReporter, the demo application.
  • MetadataViewer, a utility application to display and edit metadata.
  • SquareOneSoftware.dll, an example plug-in assembly.

Between them, these assemblies cover most aspects of working with EasiReports.

Package

EasiReports is a single strong-named assembly written entirely in managed C# -- so you can just copy it to your application directory. It is about 1 MB in size.

Update: EasiReports now references the Puzzle source code editor which is packaged in four assemblies. If you want to allow your users to edit the integrated algorithms, you must also copy these assemblies to your application directory.

Controls

EasiReports supports several types of controls, from simple lines to aggregate functions on user-defined data algorithms. All controls allow you to modify their behaviour at runtime from within the code behind the report.

Algorithms

A very powerful feature is the ability to write code behind reports. Based on an event-driven pattern, you can modify the runtime behaviour of reports, even to the extent of drawing directly onto the page Graphics object.

C# and VB compilers

Choose your language –- these integrated compilers give you and your users virtually unlimited flexibility. Intuitive design allows you to write algorithms at the report, data, section, and control levels.

Visual Studio

Use any .NET language to produce a CLR assembly and you can reference it from within EasiReports at runtime. You can use this feature to build a library of common functionality, or to extend EasiReports from the comfort of Visual Studio. The source code for an assembly providing two classes is included with the example reports.

Object Model

The entire public report object model is accessible from the host application as well as from runtime code. This allows you to build or modify reports dynamically.

Example Reports

EasiReports includes many example reports, from the most simple to the very advanced. These show the capabilities of EasiReports and also show how to accomplish common reporting requirements.

Metadata

EasiReports can automatically interrogate your database for metadata about tables, fields, primary and foreign keys. While this is the preferred method of collecting metadata, the object model is public to allow you full control over which parts of your database are available to the user.

Help

A comprehensive help file with over 1000 pages is provided to aid your development. This includes:

  • A "Walkthrough" to show you how to add EasiReports to your application.
  • A .NET style reference section for the entire public object model.
  • Sections on Algorithms and DataSources for advanced users.
  • Many example reports to show the capabilities of EasiReports.

The full HTML source and HTML Help Workshop project files are provided and may be used in your application’s help file.

Support

I am committed to providing the best technical support available. Adding EasiReports to your applications has been made quite simple and is explained in detail in the help file. If you want additional help, you can email me and I will do my best to help you. You can also request support for writing complex reports.

Conclusion

EasiReports is over 60,000 lines of code. I hope that you find it useful.

History

  • Version 4.8: 06 Feb 2006
    • Improved access to alternative data sources.
    • Syntax highlighted integrated code editors.
  • Version 4.6: 01 Aug 2005: Initial release.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Nicholas Butler

United Kingdom United Kingdom

I built my first computer, a Sinclair ZX80, on my 11th birthday in 1980.
In 1992, I completed my Computer Science degree and built my first PC.
I discovered C# and .NET 1.0 Beta 1 in late 2000 and loved them immediately.
I have been writing concurrent software professionally, using multi-processor machines, since 1995.

In real life, I have spent 3 years travelling abroad,
I have held a UK Private Pilots Licence for 20 years,
and I am a PADI Divemaster.

I now live near idyllic Bournemouth in England.

If you would like help with multithreading, please contact me via my website:


I can work 'virtually' anywhere!

Comments and Discussions

 
GeneralRe: Deploying reports - little problem with dlls Pin
BarCode5-Jun-06 22:49
memberBarCode5-Jun-06 22:49 
AnswerRe: Deploying reports - little problem with dlls Pin
Nicholas Butler7-Jun-06 3:23
memberNicholas Butler7-Jun-06 3:23 
QuestionHow to pass parameter or sql from code? Pin
BarCode2-Jun-06 3:33
memberBarCode2-Jun-06 3:33 
AnswerRe: How to pass parameter or sql from code? Pin
Nicholas Butler2-Jun-06 3:55
memberNicholas Butler2-Jun-06 3:55 
QuestionHow to connect to SQLServer Express 2005 Pin
Tushar Bhatt1-May-06 22:35
memberTushar Bhatt1-May-06 22:35 
QuestionCan Page Size changable ? Pin
Tushar Bhatt1-May-06 1:33
memberTushar Bhatt1-May-06 1:33 
AnswerRe: Can Page Size changable ? Pin
Nicholas Butler1-May-06 1:53
memberNicholas Butler1-May-06 1:53 
GeneralIs it compatible with .NET 2.0 and VS 2005 Pin
Tushar Bhatt1-May-06 1:18
memberTushar Bhatt1-May-06 1:18 
GeneralRe: Is it compatible with .NET 2.0 and VS 2005 Pin
Nicholas Butler1-May-06 1:49
memberNicholas Butler1-May-06 1:49 
QuestionExport Pin
Tonik30-Mar-06 23:16
memberTonik30-Mar-06 23:16 
AnswerRe: Export Pin
Nicholas Butler30-Mar-06 23:36
memberNicholas Butler30-Mar-06 23:36 
GeneralRe: Export Pin
Tonik31-Mar-06 0:45
memberTonik31-Mar-06 0:45 
AnswerRe: Export Pin
Nicholas Butler31-Mar-06 1:17
memberNicholas Butler31-Mar-06 1:17 
GeneralRe: Export Pin
Tonik31-Mar-06 1:52
memberTonik31-Mar-06 1:52 
QuestionNo ForeignKey in my tables? Pin
Reggie Rippetoe13-Mar-06 12:42
memberReggie Rippetoe13-Mar-06 12:42 
AnswerRe: No ForeignKey in my tables? Pin
Nicholas Butler13-Mar-06 18:44
memberNicholas Butler13-Mar-06 18:44 
GeneralCan't create Connection with ODBC Provider Pin
BarneyG777-Mar-06 23:16
memberBarneyG777-Mar-06 23:16 
AnswerRe: Can't create Connection with ODBC Provider Pin
Nicholas Butler7-Mar-06 23:35
memberNicholas Butler7-Mar-06 23:35 
Generalweb form viewer Pin
germgerm22-Feb-06 6:28
membergermgerm22-Feb-06 6:28 
AnswerRe: web form viewer Pin
Nicholas Butler22-Feb-06 6:32
memberNicholas Butler22-Feb-06 6:32 
QuestionCan Datafield automatically grow? Pin
BarneyG7722-Feb-06 1:40
memberBarneyG7722-Feb-06 1:40 
AnswerRe: Can Datafield automatically grow? Pin
Nicholas Butler22-Feb-06 1:59
memberNicholas Butler22-Feb-06 1:59 
GeneralRe: Can Datafield automatically grow? Pin
BarneyG7722-Feb-06 2:37
memberBarneyG7722-Feb-06 2:37 
QuestionImages in reports Pin
Aljaz2421-Feb-06 23:12
memberAljaz2421-Feb-06 23:12 
AnswerRe: Images in reports Pin
Nicholas Butler21-Feb-06 23:22
memberNicholas Butler21-Feb-06 23:22 
JokeRe: Images in reports Pin
Aljaz2421-Feb-06 23:36
memberAljaz2421-Feb-06 23:36 
GeneralRe: Images in reports Pin
Nicholas Butler21-Feb-06 23:42
memberNicholas Butler21-Feb-06 23:42 
AnswerRe: Images in reports Pin
Aljaz2422-Feb-06 0:26
memberAljaz2422-Feb-06 0:26 
GeneralProblems connecting SQL Express Database Pin
johan_b20-Feb-06 7:35
memberjohan_b20-Feb-06 7:35 
GeneralRe: Problems connecting SQL Express Database Pin
Nicholas Butler21-Feb-06 23:29
memberNicholas Butler21-Feb-06 23:29 
QuestionData series - how to? Pin
BarCode20-Feb-06 3:58
memberBarCode20-Feb-06 3:58 
AnswerRe: Data series - how to? Pin
Nicholas Butler20-Feb-06 4:04
memberNicholas Butler20-Feb-06 4:04 
Generalvs Crystal Reports Pin
Bernhard Elbl13-Feb-06 6:12
memberBernhard Elbl13-Feb-06 6:12 
GeneralRe: vs Crystal Reports Pin
FZelle13-Feb-06 9:13
memberFZelle13-Feb-06 9:13 
GeneralRe: vs Crystal Reports Pin
eric feng14-Feb-06 7:12
membereric feng14-Feb-06 7:12 
GeneralRe: vs Crystal Reports Pin
hpetriffer16-Mar-06 19:55
memberhpetriffer16-Mar-06 19:55 
GeneralPrinter settings Pin
Andi Fandrich9-Feb-06 1:16
memberAndi Fandrich9-Feb-06 1:16 
AnswerRe: Printer settings Pin
Nicholas Butler9-Feb-06 5:05
memberNicholas Butler9-Feb-06 5:05 
GeneralRe: Printer settings Pin
Andi Fandrich9-Feb-06 5:38
memberAndi Fandrich9-Feb-06 5:38 
GeneralSetting the report's DataSource programmaticaly Pin
Andi Fandrich8-Feb-06 22:05
memberAndi Fandrich8-Feb-06 22:05 
GeneralRe: Setting the report's DataSource programmaticaly Pin
Nicholas Butler8-Feb-06 22:17
memberNicholas Butler8-Feb-06 22:17 
GeneralRe: Setting the report's DataSource programmaticaly Pin
Andi Fandrich8-Feb-06 22:47
memberAndi Fandrich8-Feb-06 22:47 
QuestionA few questions Pin
Andi Fandrich1-Feb-06 0:55
memberAndi Fandrich1-Feb-06 0:55 
AnswerRe: A few questions Pin
Nicholas Butler1-Feb-06 1:21
memberNicholas Butler1-Feb-06 1:21 
GeneralRe: A few questions Pin
Andi Fandrich1-Feb-06 5:35
memberAndi Fandrich1-Feb-06 5:35 
NewsBeta testers wanted Pin
Nicholas Butler8-Dec-05 23:17
memberNicholas Butler8-Dec-05 23:17 
GeneralXML as datasource Pin
BarCode21-Sep-05 3:23
memberBarCode21-Sep-05 3:23 
GeneralRe: XML as datasource Pin
Nicholas Butler22-Sep-05 2:05
memberNicholas Butler22-Sep-05 2:05 
QuestionVS.NET 2005 useability ?? Pin
Lukky6-Sep-05 5:53
memberLukky6-Sep-05 5:53 
AnswerRe: VS.NET 2005 useability ?? Pin
Nicholas Butler6-Sep-05 9:03
memberNicholas Butler6-Sep-05 9:03 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.150428.2 | Last Updated 13 Feb 2006
Article Copyright 2005 by Nicholas Butler
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid