DataGridViewRowPostPaintEventArgs.PaintCellsBackground 方法

定義

繪製所指定界限內區域的儲存格背景。

public:
 void PaintCellsBackground(System::Drawing::Rectangle clipBounds, bool cellsPaintSelectionBackground);
public void PaintCellsBackground (System.Drawing.Rectangle clipBounds, bool cellsPaintSelectionBackground);
member this.PaintCellsBackground : System.Drawing.Rectangle * bool -> unit
Public Sub PaintCellsBackground (clipBounds As Rectangle, cellsPaintSelectionBackground As Boolean)

參數

clipBounds
Rectangle

Rectangle,指定要繪製的 DataGridView 區域。

cellsPaintSelectionBackground
Boolean

true 表示以 SelectionBackColorInheritedStyle 屬性的色彩繪製所指定界限的背景;false 則表示要以 BackColorInheritedStyle 屬性的色彩繪製所指定界限的背景。

例外狀況

RowIndex 小於零或大於 DataGridView 控制項的資料列數減一。

適用於

另請參閱