I have to create reviews inside a C# .Internet Home windows application. I have got an SQL Server 2005 database, Visual Studio 2005 and am quite Comfortable with creating saved methods and datasets.

Can someone please point me within the right direction for creating reviews? I simply can't appear settle your differences. Some good examples will be a nice beginning, or perhaps a simple How-to tutorial... anything really that's a little better described compared to MSDN paperwork.

I am while using CrystalDecisions.Home windows.Forms.CrystalReportViewer control to show the reviews, I presume this is.

If I am going to attempt a lengthy and sophisticated journey, what is the easiest method to create and display reviews that may also be printed?

Very is a possible selection for creating reviews. It's been around a very long time and lots of people appear to love it.

You might like to have a look at SQL confirming services. I have tried personally both but my preferance is SQL confirming services. Its pretty much built-into studio and works like the other microsoft projects. It is also free using the sql express etc.

This is an excellent article on beginning confirming services: http://www.simple-talk.com/sql/learn-sql-server/beginning-sql-server-2005-confirming-services-part-1/

I've handled to make this happen now.

Brief Overview

It functions by getting a 'data class' which is simply a regular C# class that contains variables with no code. Your particulars are often instantiated and full of data after which placed in a ArrayList. The ArrayList is certain to the report viewer, together with the title from the are accountable to load. Within the report designer '.Internet Objects' are utilized, instead of interacting using the database.

Explanation

I produced a category to keep the information for the. These kinds is by hand filled by me by by hand locating data in the database. The way you do that does not matter, but here's a good example:

DataSet ds = GeneratePickingNoteDataSet(id);
foreach (DataRow row in ds.Tables[0].Rows) {
    CPickingNoteData pickingNoteData = new CPickingNoteData();

    pickingNoteData.delivery_date = (DateTime)row["delivery_date"];
    pickingNoteData.cust_po = (int)row["CustomerPONumber"];
    pickingNoteData.address = row["CustomerAddress"].ToString();
    // ... and so on ...

    rptData.Add(pickingNoteData);
}

The category will be put in a ArrayList. Each aspect in the arraylist matches one 'row' within the finished report.

The very first aspect in their email list may also contain the report header data, and also the last aspect in their email list holds the report footer data. And since this is an ArrayList, normal Array access may be used to reach them:

((CPickingNoteData)rptData[0]).header_date = DateTime.Now;
((CPickingNoteData)rptData[rptData.Count-1]).footer_serial = GenerateSerialNumber();

After you have an arraylist filled with data, bind it for your report viewer such as this, where 'rptData' is of type 'ArrayList'

ReportDocument reportDoc = new ReportDocument();
reportDoc.Load(reportPath);
reportDoc.SetDataSource(rptData);
crystalReportViewer.ReportSource = reportDoc;

Now you will have to bind your computer data class towards the report itself. You need to do this within the designer:

  1. Open the Area Explorer tab (which can be underneath the 'View' menu), and right-click "Database Fields"
  2. Click 'Project Data'
  3. Click '.Internet Objects'
  4. Scroll lower their email list to locate your data class (whether it is not there, compile the application)
  5. Press '>>' after which OK
  6. Now you can drag the category people to the report and place them as you would like.

I second alex's recommendation to check out sql confirming services - for those who have a sql developer license, then you definitely most likely curently have confirming services

i do not like very reviews, an excessive amount of tedium within the designer (editing expressions constantly) a lot of server-deployment issues (check individuals license files!)