DataGridViewCell.GetInheritedStyle Método
Definição
Importante
Algumas informações se referem a produtos de pré-lançamento que podem ser substancialmente modificados antes do lançamento. A Microsoft não oferece garantias, expressas ou implícitas, das informações aqui fornecidas.
Obtém o estilo aplicado à célula.
public:
virtual System::Windows::Forms::DataGridViewCellStyle ^ GetInheritedStyle(System::Windows::Forms::DataGridViewCellStyle ^ inheritedCellStyle, int rowIndex, bool includeColors);
public virtual System.Windows.Forms.DataGridViewCellStyle GetInheritedStyle(System.Windows.Forms.DataGridViewCellStyle inheritedCellStyle, int rowIndex, bool includeColors);
public virtual System.Windows.Forms.DataGridViewCellStyle GetInheritedStyle(System.Windows.Forms.DataGridViewCellStyle? inheritedCellStyle, int rowIndex, bool includeColors);
abstract member GetInheritedStyle : System.Windows.Forms.DataGridViewCellStyle * int * bool -> System.Windows.Forms.DataGridViewCellStyle
override this.GetInheritedStyle : System.Windows.Forms.DataGridViewCellStyle * int * bool -> System.Windows.Forms.DataGridViewCellStyle
Public Overridable Function GetInheritedStyle (inheritedCellStyle As DataGridViewCellStyle, rowIndex As Integer, includeColors As Boolean) As DataGridViewCellStyle
Parâmetros
- inheritedCellStyle
- DataGridViewCellStyle
Um DataGridViewCellStyle a ser preenchido com o estilo de célula herdado.
- rowIndex
- Int32
O índice da linha pai da célula.
- includeColors
- Boolean
true para incluir cores herdadas no estilo de célula retornado; caso contrário, false.
Retornos
Um DataGridViewCellStyle que inclui as configurações de estilo da célula herdada da linha pai, coluna e DataGridView.
Exceções
A célula não tem nenhuma associação DataGridView.
- ou -
ColumnIndex é menor que 0, indicando que a célula é uma célula de cabeçalho de linha.
rowIndex é menor que 0 ou maior ou igual ao número de linhas no pai DataGridView.
Comentários
Esse método retorna um DataGridViewCellStyle que herda suas configurações dos DataGridViewCellStyle objetos da linha, coluna e DataGridView. Para obter mais informações, consulte Estilos de célula no controle DataGridView do Windows Forms.