Area Class
Represents an area in a report. An area is a group of like sections in the report that all share the same characteristics.
Namespace CrystalDecisions.CrystalReports.Engine Assembly CrystalDecisions.CrystalReports.Engine (CrystalDecisions.CrystalReports.Engine.dll)
Syntax
'Declaration
Public Class Area
Inherits EngineObjectBase
Implements IDisposable
public class Area : EngineObjectBase, IDisposable
Remarks
Retrieve the Area object by index or by name through the Item Property of the Areas collection.
Example
This example shows how to suppress the ReportHeader area in a ReportDocument. The method takes a ReportDocument parameter.
'Declaration
Private Sub SuppressReportHeaderArea(ByVal myReportDocument As ReportDocument)
Dim myReportDefinition As ReportDefinition
myReportDefinition = myReportDocument.ReportDefinition()
Dim myAreas As Areas
myAreas = myReportDefinition.Areas()
Dim myArea As Area
For Each myArea In myAreas
If myArea.Kind = AreaSectionKind.ReportHeader Then
Dim myAreaFormat As AreaFormat
myAreaFormat = myArea.AreaFormat()
myAreaFormat.EnableSuppress = True
End If
Next
End Sub
private void SuppressReportHeaderArea(ReportDocument reportDocument)
{
ReportDefinition reportDefinition = reportDocument.ReportDefinition;
Areas areas = reportDefinition.Areas;
for (int i=0; i < areas.Count; i++)
{
Area area = areas[i];
if (area.Kind == AreaSectionKind.ReportHeader)
{
AreaFormat areaFormat = area.AreaFormat;
areaFormat.EnableSuppress = true;
}
}
}
Inheritance Hierarchy
Object
EngineObjectBase
Area
Version Information
Crystal Reports Basic for Visual Studio 2008
Supported since: Crystal Reports for Visual Studio .NET 2002
See Also
Reference
Area Members
CrystalDecisions.CrystalReports.Engine Namespace