Editar

Compartilhar via


DataGridView.GetColumnDisplayRectangle(Int32, Boolean) Method

Definition

Returns the rectangle that represents the display area for a column, as determined by the column index.

public:
 System::Drawing::Rectangle GetColumnDisplayRectangle(int columnIndex, bool cutOverflow);
public System.Drawing.Rectangle GetColumnDisplayRectangle (int columnIndex, bool cutOverflow);
member this.GetColumnDisplayRectangle : int * bool -> System.Drawing.Rectangle
Public Function GetColumnDisplayRectangle (columnIndex As Integer, cutOverflow As Boolean) As Rectangle

Parameters

columnIndex
Int32

The column index for the desired cell.

cutOverflow
Boolean

true to return the column rectangle visible in the DataGridView bounds; false to return the entire column rectangle.

Returns

The Rectangle that represents the display rectangle of the column.

Exceptions

columnIndex is not in the valid range of 0 to the number of columns minus 1.

Applies to

See also