StyleGrid REALbasic Plugin |

# StyleGridCell.Image Property

To set a picture in the cell.

Image as StyleGridPicture {Read and Write}

#### Remarks

This property can only be used if the cell has been Extended.
Extended cells have been given permission to consume more memory to support the extended features.
This property also works on Header cells.
Example for REALbasic 5.5 or later:

Sub ControlCreated()
// We can only set images in columns that have been defined as Extended
me.Column(1).CellFactoryID = CellFactoryType.Extended
End Sub
Sub Action()
Dim row as StyleGridRow
StyleGrid1.LockDrawing = true
row = new StyleGridRow(StyleGrid1)
row.WritableCell(1).Image = new StyleGridPicture(Key,2,2)
StyleGrid1.AppendRow(row)
StyleGrid1.LockDrawing = false
End Sub
Example for REALbasic older than 5.5:
Sub ControlCreated()
// We can only set images in columns that have been defined as Extended
me.Column(1).CellFactoryID = 1
End Sub
Sub Action()
Dim row as StyleGridRow
StyleGrid1.LockDrawing = true
row = new StyleGridRow(StyleGrid1)
row.WritableCell(1).Image = new StyleGridPicture(Key,2,2)
StyleGrid1.AppendRow(row)
StyleGrid1.LockDrawing = false
End Sub

#### See Also

StyleGridCell Class