DataGridViewCellPaintingEventArgs.PaintBackground(Rectangle, Boolean) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Peint l’arrière-plan de la cellule pour la zone dans les limites spécifiées.
public:
void PaintBackground(System::Drawing::Rectangle clipBounds, bool cellsPaintSelectionBackground);
public void PaintBackground(System.Drawing.Rectangle clipBounds, bool cellsPaintSelectionBackground);
member this.PaintBackground : System.Drawing.Rectangle * bool -> unit
Public Sub PaintBackground (clipBounds As Rectangle, cellsPaintSelectionBackground As Boolean)
Paramètres
- clipBounds
- Rectangle
Qui Rectangle spécifie la zone de la DataGridView peinture.
- cellsPaintSelectionBackground
- Boolean
true pour peindre l’arrière-plan des limites spécifiées avec la couleur de la SelectionBackColor propriété du InheritedStyle; false pour peindre l’arrière-plan des limites spécifiées avec la couleur de la BackColor propriété du InheritedStyle.
Exceptions
RowIndex est inférieur à -1 ou supérieur ou égal au nombre de lignes dans le DataGridView contrôle.
- ou -
ColumnIndex est inférieur à -1 ou supérieur ou égal au nombre de colonnes dans le DataGridView contrôle.