ConfigureCellText

Top  Previous  Next

Specifies the multiple lines (up to 4) of texts that are drawn onto an individual cell for the grid in readonly mode - either the full grid or a sub grid.

[Visual Basic .NET]

Public Function ConfigureCellText(ByVal GridIndex As Integer,

                                                  ByVal SectionIndex As Integer,

                                                  ByVal RowIndex As Integer,

                                                  ByVal ColumnIndex As Integer,

                                                  ByVal Line_1 As String,

                                                  ByVal IsLink_1 As Boolean,

                                                  ByVal Line_2 As String,

                                                  ByVal IsLink_2 As Boolean,

                                                  ByVal Line_3 As String,

                                                  ByVal IsLink_3 As Boolean,

                                                  ByVal Line_4 As String,

                                                  ByVal IsLink_4 As Boolean,

                                                  ByVal BackColor As Integer,

                                                  ByVal ForeColor As Integer,

                                                  ByVal Alignment As Integer) As Boolean

[C#]

public bool ConfigureCellText(int GridIndex,

                                           int SectionIndex,

                                           int RowIndex,

                                           int ColumnIndex,

                                           string Line_1,

                                           bool IsLink_1,

                                           string Line_2,

                                           bool IsLink_2,

                                           string Line_3,

                                           bool IsLink_3,

                                           string Line_4,

                                           bool IsLink_4,

                                           long BackColor,

                                           long ForeColor,

                                           int Alignment);

Parameters

GridIndex

Specifies the grid index - either the full gird or a sub grid. -1 indicates the full grid; for a sub grid, the parameter's value must be between 0 and the return value of GetTotalSubGrids() minus 1.

SectionIndex

Specifies the index (0-based) of the section in which the cell resides. If the AllowSections is set to FALSE, this parameter becomes irrelevant.

RowIndex

Specifies the index (0-based) of the row in which the cell resides.

ColumnIndex

Specifies the index (0-based) of the column in which the cell resides.

Line_1

Specifies the 1st line of Unicode text that is drawn onto the cell, and an empty string can be assigned here.

IsLink_1

Specifies whether the 1st line of Unicode text is a linked text or not.

Line_2

Specifies the 2nd line of Unicode text that is drawn onto the cell, and an empty string can be assigned here.

IsLink_2

Specifies whether the 2nd line of Unicode text is a linked text or not.

Line_3

Specifies the 3rd line of Unicode text that is drawn onto the cell, and an empty string can be assigned here.

IsLink_3

Specifies whether the 3rd line of Unicode text is a linked text or not.

Line_4

Specifies the 4th line of Unicode text that is drawn onto the cell, and an empty string can be assigned here.

IsLink_4

Specifies whether the 4th line of Unicode text is a linked text or not.

BackColor

Specifies the cell background's color value in 32-bit ARGB format. If it is 1, the background color will be determined by the GridBackColor property of the control. For example, -65536 can be passed to indicate the red color, as Color.Red.ToArgb() returns -65536.

ForeColor

Specifies the cell text's color value in 32-bit ARGB format. If it is 1, the text color will be determined by the RowTextColor property of the control.

Alignment

Specifies the alignment's type, and all valid values are listed below:

Value

Comment

0

If ConfigureCellImage() is not called, all texts are left-aligned. Otherwise the alignment will be determined by that API.

1

If ConfigureCellImage() is not called, all texts are center-aligned. Otherwise the alignment will be determined by that API.

2

If ConfigureCellImage() is not called, all texts are right-aligned. Otherwise the alignment will be determined by that API.

 

 

Return Value:

If the operation is successful, it returns TRUE; otherwise it returns FALSE. For example, one or more index values are out of bound.

 

Remarks

The sync cell in the associated grid is automatically configured.