Class MatrixDescriptor
The base class for matrix element descriptors such as MatrixHeaderDescriptor and MatrixCellDescriptor.
Implements
Namespace: FastReport.Matrix
Assembly: FastReport.Base.dll
Syntax
public class MatrixDescriptor : IFRSerializable
Properties
Expression
Gets or sets an expression which value will be used to fill the matrix.
Declaration
public string Expression { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Remarks
Expression may be any valid expression. Usually it's a data column:
[DataSource.Column]
.
TemplateCell
Gets or sets the template cell bound to this descriptor.
Declaration
public TableCell TemplateCell { get; set; }
Property Value
Type | Description |
---|---|
TableCell |
Remarks
Using this property, you may access the matrix cell which is bound to this descriptor. It may be useful to change the cell's appearance.
note
Before using this property, you must initialize the matrix descriptors by calling the BuildTemplate() method.
Examples
MatrixObject matrix;
// change the fill color of the first matrix cell
matrix.Data.Cells[0].TemplateCell.Fill = new SolidFill(Color.Red);
TemplateColumn
Gets or sets the template column bound to this descriptor.
Declaration
public TableColumn TemplateColumn { get; set; }
Property Value
Type | Description |
---|---|
TableColumn |
Remarks
This property is for internal use; usually you don't need to use it.
TemplateRow
Gets or sets the template row bound to this descriptor.
Declaration
public TableRow TemplateRow { get; set; }
Property Value
Type | Description |
---|---|
TableRow |
Remarks
This property is for internal use; usually you don't need to use it.
Methods
Assign(MatrixDescriptor)
Assigns values from another descriptor.
Declaration
public virtual void Assign(MatrixDescriptor source)
Parameters
Type | Name | Description |
---|---|---|
MatrixDescriptor | source | Descriptor to assign values from. |
Deserialize(FRReader)
Deserializes the object.
Declaration
public void Deserialize(FRReader reader)
Parameters
Type | Name | Description |
---|---|---|
FRReader | reader | Reader object. |
Serialize(FRWriter)
Serializes the object.
Declaration
public virtual void Serialize(FRWriter writer)
Parameters
Type | Name | Description |
---|---|---|
FRWriter | writer | Writer object. |