Class ReportEngine
Represents the report engine.
Inheritance
Namespace: FastReport.Engine
Assembly: FastReport.Base.dll
Syntax
public class ReportEngine
Properties
AbsRowNo
Gets the running current row number of currently printing band.
Declaration
public int AbsRowNo { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Remarks
This value is 1-based.
ColumnFooterHeight
Gets the height of column footer (including all its child bands), in pixels.
Declaration
public float ColumnFooterHeight { get; }
Property Value
Type | Description |
---|---|
System.Single |
CurColumn
Gets the index of currently printing column in the multi-column report.
Declaration
public int CurColumn { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Remarks
This value is 0-based.
CurPage
Gets or sets index of current prepared page the current band will print on.
Declaration
public int CurPage { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
Remarks
Note: the page with specified index must exists. This property is used to print side-by-side subreports and Table object. Usually you don't need to use it.
CurX
Gets or sets the current X offset.
Declaration
public float CurX { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
Remarks
This property specifies the X offset where the current band will be printed.
CurY
Gets or sets the current Y offset.
Declaration
public float CurY { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
Remarks
This property specifies the Y offset where the current band will be printed. After the band is printed, this value is incremented by the band's height.
Date
Gets the date of report start.
Declaration
public DateTime Date { get; }
Property Value
Type | Description |
---|---|
System.DateTime |
FinalPass
Gets a value indicating whether the report is executing the final pass.
Declaration
public bool FinalPass { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Remarks
This property is true if report is one-pass, or if report is two-pass and the second pass is executing.
FirstPass
Gets a value indicating whether the report is executing the first pass.
Declaration
public bool FirstPass { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Remarks
This property is true if report is one-pass, or if report is two-pass and the first pass is executing.
FreeSpace
Gets the free space on the current page, in pixels.
Declaration
public float FreeSpace { get; }
Property Value
Type | Description |
---|---|
System.Single |
Remarks
This property returns the page height minus footers height minus CurY value.
HierarchyLevel
Gets a level of hierarchy when printing hierarchical bands.
Declaration
public int HierarchyLevel { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Remarks
The first level of hierarchy has 0 index.
HierarchyRowNo
Gets the row number like "1.2.1" when printing hierarchical bands.
Declaration
public string HierarchyRowNo { get; }
Property Value
Type | Description |
---|---|
System.String |
IsKeeping
Returns true of keeping is enabled
Declaration
public bool IsKeeping { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
KeepCurY
Returns keeping position
Declaration
public float KeepCurY { get; }
Property Value
Type | Description |
---|---|
System.Single |
OutlineXml
Gets xml containing outline nodes.
Declaration
public XmlItem OutlineXml { get; }
Property Value
Type | Description |
---|---|
XmlItem |
PageFooterHeight
Gets the height of page footer (including all its child bands), in pixels.
Declaration
public float PageFooterHeight { get; }
Property Value
Type | Description |
---|---|
System.Single |
PageHeight
Gets the current page height, in pixels.
Declaration
public float PageHeight { get; }
Property Value
Type | Description |
---|---|
System.Single |
Remarks
This property returns a paper height minus top and bottom margins.
PageN
Gets the string that represents the current page number.
Declaration
public string PageN { get; }
Property Value
Type | Description |
---|---|
System.String |
Remarks
This property returns a locale-based value, for example: "Page 1".
PageNo
Gets the current prepared page number.
Declaration
public int PageNo { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Remarks
This value is 1-based. The initial value (usually 1) is set in the Report.InitialPageNumber property.
PageNofM
Gets the string that represents the "Page N of M" number.
Declaration
public string PageNofM { get; }
Property Value
Type | Description |
---|---|
System.String |
Remarks
This property returns a locale-based value, for example: "Page 1 of 10".
PageWidth
Gets the current page width, in pixels.
Declaration
public float PageWidth { get; }
Property Value
Type | Description |
---|---|
System.Single |
Remarks
This property returns a paper width minus left and right margins.
RowNo
Gets the current row number of currently printing band.
Declaration
public int RowNo { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Remarks
This value is 1-based. It resets to 1 on each new group.
TotalPages
Gets the number of total pages in a prepared report.
Declaration
public int TotalPages { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Remarks
To use this property, your report must be two-pass. Set the DoublePass property to true.
UnlimitedHeight
Gets the value indicating whether the page has unlimited height.
Declaration
public bool UnlimitedHeight { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
UnlimitedHeightValue
Gets or sets the current height of unlimited page.
Declaration
public float UnlimitedHeightValue { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
UnlimitedWidth
Gets the value indicating whether the page has unlimited width.
Declaration
public bool UnlimitedWidth { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
UnlimitedWidthValue
Gets or sets the current width of unlimited page.
Declaration
public float UnlimitedWidthValue { get; set; }
Property Value
Type | Description |
---|---|
System.Single |
Methods
AddBookmark(String)
Creates a new bookmark with specified name at current position.
Declaration
public void AddBookmark(string name)
Parameters
Type | Name | Description |
---|---|---|
System.String | name |
AddOutline(String)
Creates a new outline element with specified text.
Declaration
public void AddOutline(string text)
Parameters
Type | Name | Description |
---|---|---|
System.String | text | Text of element. |
Remarks
After you call this method, the element will be added to the current position in the outline. The next call to AddOutline will add new element as a child of this element. To shift the position, use the OutlineRoot() or OutlineUp methods.
EndKeep()
Ends the keep mechanism.
Declaration
public void EndKeep()
Remarks
Use this method along with the StartKeep() method if you want to keep several bands together. Call StartKeep method before printing the first band you want to keep, then call the EndKeep method after printing the last band you want to keep.
GetBookmarkPage(String)
Gets a page number for the specified bookmark name.
Declaration
public int GetBookmarkPage(string name)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | Name of bookmark. |
Returns
Type | Description |
---|---|
System.Int32 | Page number if bookmark with such name found; 0 otherwise. |
Remarks
Use this method to print the table of contents in your report. Normally it can be done using bookmarks.
caution
You must set your report to double pass to use this method.
OutlineRoot()
Sets the current outline position to root.
Declaration
public void OutlineRoot()
OutlineUp()
Shifts the current outline position one level up.
Declaration
public void OutlineUp()
ProcessObject(TextObjectBase)
Processes the specified text object which ProcessAt property is set to Custom.
Declaration
public void ProcessObject(TextObjectBase obj)
Parameters
Type | Name | Description |
---|---|---|
TextObjectBase | obj | The text object to process. |
ResetLogicalPageNumber()
Resets the logical page numbers.
Declaration
public void ResetLogicalPageNumber()
ShowBand(BandBase)
Shows band at the current position.
Declaration
public void ShowBand(BandBase band)
Parameters
Type | Name | Description |
---|---|---|
BandBase | band | Band to show. |
Remarks
After the band is shown, the current position is advanced by the band's height.
ShowBandAsync(BandBase, CancellationToken)
Declaration
public async Task ShowBandAsync(BandBase band, CancellationToken cancellationToken)
Parameters
Type | Name | Description |
---|---|---|
BandBase | band | |
System.Threading.CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |
StartKeep()
Starts the keep mechanism.
Declaration
public void StartKeep()
Remarks
Use this method along with the EndKeep() method if you want to keep several bands together. Call StartKeep method before printing the first band you want to keep, then call the EndKeep method after printing the last band you want to keep.
StartNewColumn()
Starts a new column.
Declaration
public void StartNewColumn()
StartNewPage()
Starts a new page.
Declaration
public void StartNewPage()