DataGridViewRowPostPaintEventArgs(DataGridView, Graphics, Rectangle, Rectangle, Int32, DataGridViewElementStates, String, DataGridViewCellStyle, Boolean, Boolean) DataGridViewRowPostPaintEventArgs(DataGridView, Graphics, Rectangle, Rectangle, Int32, DataGridViewElementStates, String, DataGridViewCellStyle, Boolean, Boolean) DataGridViewRowPostPaintEventArgs(DataGridView, Graphics, Rectangle, Rectangle, Int32, DataGridViewElementStates, String, DataGridViewCellStyle, Boolean, Boolean) Constructor

定义

初始化 DataGridViewRowPostPaintEventArgs 类的新实例。Initializes a new instance of the DataGridViewRowPostPaintEventArgs class.

public:
 DataGridViewRowPostPaintEventArgs(System::Windows::Forms::DataGridView ^ dataGridView, System::Drawing::Graphics ^ graphics, System::Drawing::Rectangle clipBounds, System::Drawing::Rectangle rowBounds, int rowIndex, System::Windows::Forms::DataGridViewElementStates rowState, System::String ^ errorText, System::Windows::Forms::DataGridViewCellStyle ^ inheritedRowStyle, bool isFirstDisplayedRow, bool isLastVisibleRow);
public DataGridViewRowPostPaintEventArgs (System.Windows.Forms.DataGridView dataGridView, System.Drawing.Graphics graphics, System.Drawing.Rectangle clipBounds, System.Drawing.Rectangle rowBounds, int rowIndex, System.Windows.Forms.DataGridViewElementStates rowState, string errorText, System.Windows.Forms.DataGridViewCellStyle inheritedRowStyle, bool isFirstDisplayedRow, bool isLastVisibleRow);
new System.Windows.Forms.DataGridViewRowPostPaintEventArgs : System.Windows.Forms.DataGridView * System.Drawing.Graphics * System.Drawing.Rectangle * System.Drawing.Rectangle * int * System.Windows.Forms.DataGridViewElementStates * string * System.Windows.Forms.DataGridViewCellStyle * bool * bool -> System.Windows.Forms.DataGridViewRowPostPaintEventArgs

参数

dataGridView
DataGridView DataGridView DataGridView

要绘制的行所属的 DataGridViewThe DataGridView that owns the row that is being painted.

graphics
Graphics Graphics Graphics

用于绘制 GraphicsDataGridViewRowThe Graphics used to paint the DataGridViewRow.

clipBounds
Rectangle Rectangle Rectangle

Rectangle,它表示需要绘制的 DataGridView 区域。A Rectangle that represents the area of the DataGridView that needs to be painted.

rowBounds
Rectangle Rectangle Rectangle

包含要绘制的 Rectangle 的边界的 DataGridViewRowA Rectangle that contains the bounds of the DataGridViewRow that is being painted.

rowIndex
Int32 Int32 Int32

当前所绘制的单元格的行索引。The row index of the cell that is being painted.

rowState
DataGridViewElementStates DataGridViewElementStates DataGridViewElementStates

用于指定行的状态的 DataGridViewElementStates 值的按位组合。A bitwise combination of DataGridViewElementStates values that specifies the state of the row.

errorText
String String String

与行关联的错误消息。An error message that is associated with the row.

inheritedRowStyle
DataGridViewCellStyle DataGridViewCellStyle DataGridViewCellStyle

一个包含有关行的格式设置和样式信息的 DataGridViewCellStyleA DataGridViewCellStyle that contains formatting and style information about the row.

isFirstDisplayedRow
Boolean Boolean Boolean

若要指示当前行是 DataGridView 中当前显示的第一行,则为 true;否则为 falsetrue to indicate whether the current row is the first row currently displayed in the DataGridView; otherwise, false.

isLastVisibleRow
Boolean Boolean Boolean

若要指示当前行是 DataGridView(已将 Visible 属性设置为 true)中的最后一行,则为 true;否则为 falsetrue to indicate whether the current row is the last row in the DataGridView that has the Visible property set to true; otherwise, false.

异常

dataGridViewnulldataGridView is null.

- 或 --or- graphicsnullgraphics is null.

-or- inheritedRowStylenullinheritedRowStyle is null.

适用于

另请参阅