'Declaration
Public Overloads Sub DrawCell( _ ByVal flags As DrawCellFlags _ )
public void DrawCell( DrawCellFlags flags )
Parameters
- flags
- DrawCellFlags that specifies the parts of the cell.
'Declaration
Public Overloads Sub DrawCell( _ ByVal flags As DrawCellFlags _ )
public void DrawCell( DrawCellFlags flags )
This method is typically called in OwnerDrawCell handlers when the code intends to draw some elements of the cell but not everything.
For example, the code may want to draw a custom border only. In this case, it could call e.DrawCell(DrawCellFlags.Background | DrawCellFlags.Content) to draw the cell background and content, and later draw the custom border. Or the code could want to draw a custom marker in a cell (like a note indicator in Excel). In this case, it should call e.DrawCell() to draw the entire cell, and later add the note marker (little red triangle on the top right corner of the cell).
If the owner-draw code draws the entire cell (including the background), then there's no need to call e.DrawCell at all.