DataDefinition Class

Contains all the information relating to data manipulation based on the data source in a report.

Namespace CrystalDecisions.CrystalReports.Engine Assembly CrystalDecisions.CrystalReports.Engine (CrystalDecisions.CrystalReports.Engine.dll)


Public Class DataDefinition
    Inherits EngineObjectBase
    Implements IDisposable
public class DataDefinition : EngineObjectBase, IDisposable


You can use this class to define how to select records for both the report and for groups, as well as retrieve the group collection and the various field definition collections. Retrieve a DataDefinition object through the DataDefinition property of the ReportDocument object.


This example updates the formulas in the data definition of a report.


      Private Sub UpdateFormulas(ByVal myReportDocument As ReportDocument)
         myReportDocument.DataDefinition.FormulaFields.Item(1).Text = "{file.SALES} *.1"
         myReportDocument.DataDefinition.FormulaFields.Item(2).Text = "{file.SALES} + {file.COMMISSION}"
      End Sub
      private void UpdateFormulas(ReportDocument reportDocument)
         reportDocument.DataDefinition.FormulaFields[1].Text = "{file.SALES} *.1";
         reportDocument.DataDefinition.FormulaFields[2].Text = "{file.SALES} + {file.COMMISSION}";

Inheritance Hierarchy


Version Information

Crystal Reports Basic for Visual Studio 2008

Supported since: Crystal Reports for Visual Studio .NET 2002

See Also


DataDefinition Members
CrystalDecisions.CrystalReports.Engine Namespace