DataGridViewRowPostPaintEventArgs.PaintCells(Rectangle, DataGridViewPaintParts) DataGridViewRowPostPaintEventArgs.PaintCells(Rectangle, DataGridViewPaintParts) DataGridViewRowPostPaintEventArgs.PaintCells(Rectangle, DataGridViewPaintParts) DataGridViewRowPostPaintEventArgs.PaintCells(Rectangle, DataGridViewPaintParts) Method

定义

为指定边界中的区域绘制指定的单元格部分。Paints the specified cell parts for the area in the specified bounds.

public:
 void PaintCells(System::Drawing::Rectangle clipBounds, System::Windows::Forms::DataGridViewPaintParts paintParts);
public void PaintCells (System.Drawing.Rectangle clipBounds, System.Windows.Forms.DataGridViewPaintParts paintParts);
member this.PaintCells : System.Drawing.Rectangle * System.Windows.Forms.DataGridViewPaintParts -> unit
Public Sub PaintCells (clipBounds As Rectangle, paintParts As DataGridViewPaintParts)

参数

clipBounds
Rectangle Rectangle Rectangle Rectangle

一个指定要绘制的 Rectangle 区域的 DataGridViewA Rectangle that specifies the area of the DataGridView to be painted.

paintParts
DataGridViewPaintParts DataGridViewPaintParts DataGridViewPaintParts DataGridViewPaintParts

用于指定要绘制的部分的 DataGridViewPaintParts 值的按位组合。A bitwise combination of DataGridViewPaintParts values specifying the parts to paint.

异常

RowIndex 小于零或大于将 DataGridView 控件中的行数减一得到的值。RowIndex is less than zero or greater than the number of rows in the DataGridView control minus one.

适用于

另请参阅