Class Excel2007Export
Excel 2007 export class
Implements
Inherited Members
Namespace: FastReport.Export.OoXML
Assembly: FastReport.dll
Syntax
public class Excel2007Export : OOExportBase, IFRSerializable
Constructors
Excel2007Export()
Initializes a new instance of the class.
Declaration
public Excel2007Export()
Properties
CurrencyToAccounting
Gets or sets a value indicating that currency should be converted to accounting format.
Declaration
public bool CurrencyToAccounting { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
DataOnly
Gets or sets a value that determines whether to export the databand rows only.
Declaration
public bool DataOnly { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
ExportFormulas
Determines whether to export formulas as formulas.
Declaration
public bool ExportFormulas { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
FontScale
Gets or sets the font scale value.
Declaration
public float FontScale { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Single |
GeneralToText
Gets or sets a value indicating that general should be converted to text format.
Declaration
public bool GeneralToText { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
GroupName
Name of the selected group.
Declaration
public string GroupName { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String |
GroupOnSeparateSheet
Each group is placed on a new Excel page.
Declaration
public bool GroupOnSeparateSheet { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
MergePagesIntoSingleSheet
Specifies whether to merge all report pages into a single sheet when exporting to Excel. If set to true, all pages will be exported onto a single Excel sheet. By default, this property is disabled (false).
Declaration
public bool MergePagesIntoSingleSheet { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
PageBreaks
Gets or sets a value that determines whether to insert page breaks in the output file or not.
Declaration
public bool PageBreaks { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
PictureProperties
Gets or sets a value that determines whether to export the databand rows only.
Declaration
public Excel2007Export.ePictureProperties PictureProperties { get; set; }
Property Value
| Type | Description |
|---|---|
| Excel2007Export.ePictureProperties |
PinX
Gets or sets the pinned cells in X ordinate.
Declaration
public Dictionary<int, int> PinX { get; set; }
Property Value
| Type | Description |
|---|---|
| Dictionary<System.Int32, System.Int32> |
PinY
Gets or sets the pinned cells in Y ordinate.
Declaration
public Dictionary<int, int> PinY { get; set; }
Property Value
| Type | Description |
|---|---|
| Dictionary<System.Int32, System.Int32> |
PrintFit
Gets or sets the Print Fit Mode.
Declaration
public Excel2007Export.PrintFitMode PrintFit { get; set; }
Property Value
| Type | Description |
|---|---|
| Excel2007Export.PrintFitMode |
PrintOptimized
Enable or disable a resolution optimization.
Declaration
public bool PrintOptimized { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
PrintScale
Gets or sets the print scaling (value from 10 to 400).
Declaration
public int PrintScale { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Int32 |
Seamless
Enable or disable export of page footers and next page headers without table breaks.
Declaration
public bool Seamless { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
SheetTabColorsData
Gets or sets a serialized string containing tab colors for sheets. Format: "1\nFF808080\r" where the number is the page number (1-based) and hex is ARGB.
Declaration
public string SheetTabColorsData { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String |
SheetTabColorsEnabled
Gets or sets a value indicating whether the sheet tab colors are applied.
Declaration
public bool SheetTabColorsEnabled { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
ShowGridlines
Enable or disable show gridlines.
Declaration
public bool ShowGridlines { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
ShrinkToFit
Determines whether to enable the srink to fit property for some text objects when exporting to excel.
Declaration
public bool ShrinkToFit { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
SplitPages
Each report page is placed on a new Excel page.
Declaration
public bool SplitPages { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
UngroupSheets
Grouping or ungrouping sheets. Grouping is enabled by default.
Declaration
public bool UngroupSheets { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
UseCustomFormat
Gets or sets a value indicating whether custom formats should be used for export instead of the default general format.
Declaration
public bool UseCustomFormat { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
UseFileStream
Gets or sets a value indicating that FileStream should be used instead of MomoryStream during export.
Declaration
public bool UseFileStream { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
Remarks
Enabling this option will reduce memory consumption, but increase the time of export.
UseLocaleFormating
Gets or sets a value that determines whether the using locale data formatting.
Declaration
public bool UseLocaleFormating { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
UsePresetScale
Sets or gets the flag using the preset print scale.
Declaration
public bool UsePresetScale { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
Wysiwyg
Gets or sets a value that determines whether the wysiwyg mode should be used for better results.
Declaration
public bool Wysiwyg { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
Remarks
Default value is true. In wysiwyg mode, the resulting Excel file will look as close as possible to the prepared report. On the other side, it may have a lot of small rows/columns, which will make it less editable. If you set this property to false, the number of rows/columns in the resulting file will be decreased. You will get less wysiwyg, but more editable file.
Methods
Deserialize(FRReader)
Deserializes the object.
Declaration
public override void Deserialize(FRReader reader)
Parameters
| Type | Name | Description |
|---|---|---|
| FRReader | reader | Reader object. |
Overrides
Remarks
Do not call this method directly. You should override it if you are developing a new component for FastReport.
This method is called when the object needs to restore the state. It may happen when:
- loading the report from a file or stream;
- loading the report from the designer's undo buffer;
- assigning another object to this object using the Assign(Base) or AssignAll(Base) methods;
- loading the object from the designer's clipboard;
ExportBand(BandBase)
This method is called for each band on exported page.
Declaration
protected override void ExportBand(BandBase band)
Parameters
| Type | Name | Description |
|---|---|---|
| BandBase | band | Band, dispose after method compite. |
Overrides
ExportPageBegin(ReportPage)
This method is called at the start of exports of each page.
Declaration
protected override void ExportPageBegin(ReportPage page)
Parameters
| Type | Name | Description |
|---|---|---|
| ReportPage | page | Page for export may be empty in this method. |
Overrides
ExportPageEnd(ReportPage)
This method is called at the end of exports of each page.
Declaration
protected override void ExportPageEnd(ReportPage page)
Parameters
| Type | Name | Description |
|---|---|---|
| ReportPage | page | Page for export may be empty in this method. |
Overrides
Finish()
This method is called when the export is finished.
Declaration
protected override void Finish()
Overrides
GetFileFilter()
Returns a file filter for a save dialog.
Declaration
protected override string GetFileFilter()
Returns
| Type | Description |
|---|---|
| System.String | String that contains a file filter, for example: "Bitmap image (.bmp)|.bmp" |
Overrides
GetFileName()
Gets the file name to export to.
Declaration
public string GetFileName()
Returns
| Type | Description |
|---|---|
| System.String | The full file name to export to. |
Serialize(FRWriter)
Serializes the object.
Declaration
public override void Serialize(FRWriter writer)
Parameters
| Type | Name | Description |
|---|---|---|
| FRWriter | writer | Writer object. |
Overrides
Remarks
Do not call this method directly. You should override it if you are developing a new component for FastReport.
This method is called when the object needs to save the state. It may happen when:
- saving the report to the file or stream;
- saving the report to the designer's undo buffer;
- assigning the object to another object using the Assign(Base) or AssignAll(Base) methods;
- saving the object to the designer's clipboard;
- saving the object to the preview (when run a report).
Start()
This method is called when the export starts.
Declaration
protected override void Start()