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

Binding more than one Custom Class (Business Entity) to Crystal Report

Status
Not open for further replies.

hcnielsen

Programmer
Feb 26, 2008
1
NO
Hello
I have problems to bind more than one Custom Class(Business Entity) to Crystal Report (There is no direct access to the database, instead we use a n-tier approach).
To give an example, I want to make an Invoice with an InvoiceHead and an ArrayList of InvoiceDetails. The code in C# for these Custom Classes(Business Entities) are as follows:

public class InvoiceHead
{
public int InvoiceHeadID { get; set; }
public string InvoiceHeadCustomerName { get; set; }
}
public class InvoiceDetail
{
public int InvoiceHeadID { get; set; }
public int InvoiceDetailID { get; set; }
public string InvoiceDetailProduct { get; set; }
public int InvoiceDetailPrice { get; set; }
}

I manage to show the InvoiceDetail by using the SetDataSource method to the ArrayList of InvoiceDetail, but how do I get the data in the object of InvoiceHead to show on my Crystal Report?
I am a newbie to Crystal Reports and any help would be appreciated (in C#)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top