A cell's color scheme when selected.

Usage

Set_Property(OLECtrlEntID, "OLE.CellSelColors[field; record]", Array)

Values

Array has the following structure:

PosNameTypeDescriptionDefault
<1>Selected Cell Foreground ColorColorColor of the cell's text when it is selectedNone
<2>Selected Cell Background ColorColor FillThe cell's background when it is selectedNone
<3>Selected Record Foreground ColorColorColor of the cell's text when it's record is selectedNone
<4>Selected Record Background ColorColor FillThe cell's background when it's record is selectedNone
<5>Selected Column Foreground ColorColorColor of the cell's text when it's column is selectedNone
<6>Selected Column Background ColorColor FillThe cell's background when it's column is selectedNone

Indices

IndexDescription
fieldIndex to an existing field
recordIndex to an existing record

Remarks

The CellSelColors property allows you to customize the color of individual cells based on their selection state.

Selected Cell

The first two fields specify the text color and background used to render the cell when it is the selected cell. When set to "None", the colors specified in the SelectionStyle property are used.

Selected Record

The next two fields specify the text color and background used to render the cell when it's record is selected. The record is considered selected when any cell within it is the selected cell. When set to "None", the colors specified in the SelectionStyle property are used.

Selected Column

The last two fields specify the text color and background used to render the cell when it's column is selected. The column is considered selected when any cell within it is the selected cell. When set to "None", the colors specified in the SelectionStyle property are used.

Example

// Color code related cells 
Ctrl = @Window:".OLE_EDITTABLE" 
CellColors = "" 

// Fields 1-4 (Red) 
CellColors<2> = "Gradient(Red L=85, Red L=80, 6)" 
CellColors<4> = "Gradient(Red L=95, Red L=90, 6)" 
Set_Property(Ctrl, "OLE.CellSelColors[1-4;All]", CellColors) 

// Field 5 (Orange) 
CellColors<2> = "Gradient(Orange L=85, Orange L=75, 6)" 
CellColors<4> = "Gradient(Orange L=95, Orange L=85, 6)" 
Set_Property(Ctrl, "OLE.CellSelColors[5;All]", CellColors) 

// Fields 6 & 7 (Yellow) 
CellColors<2> = "Gradient(Yellow L=80, Yellow L=70, 6)" 
CellColors<4> = "Gradient(Yellow L=90, Yellow L=80, 6)" 
Set_Property(Ctrl, "OLE.CellSelColors[6-7;All]", CellColors) 

// Fields 8 & 9 (Green) 
CellColors<2> = "Gradient(Lime L=85, Lime L=80, 6)" 
CellColors<4> = "Gradient(Lime L=95, Lime L=90, 6)" 
Set_Property(Ctrl, "OLE.CellSelColors[8-9;All]", CellColors) 

// Fields 10-14 (Blue) 
CellColors<2> = "Gradient(Blue L=85, Blue L=80, 6)" 
CellColors<4> = "Gradient(Blue L=95, Blue L=90, 6)" 
Set_Property(Ctrl, "OLE.CellSelColors[10-14;All]", CellColors) 

// Fields 15-16 (Purple) 
CellColors<2> = "Gradient(Purple L=85, Purple L=80, 6)" 
CellColors<4> = "Gradient(Purple L=95, Purple L=90, 6)" 
Set_Property(Ctrl, "OLE.CellSelColors[15-16;All]", CellColors)

See Also

AutoColorsSelectionStyleHeaderColorsCellColors

  • No labels