Couleur bouton selon valeur cellule
Résolu
surplus
Messages postés
673
Date d'inscription
Statut
Membre
Dernière intervention
-
surplus Messages postés 673 Date d'inscription Statut Membre Dernière intervention -
surplus Messages postés 673 Date d'inscription Statut Membre Dernière intervention -
A voir également:
- Couleur bouton selon valeur cellule
- Excel cellule couleur si condition texte - Guide
- Bouton couleur telecommande - Guide
- Excel compter cellule couleur sans vba - Guide
- Excel si couleur cellule alors ✓ - Forum Excel
- Proteger cellule excel - Guide
2 réponses
Bonjour,
Comme cela
Private Sub Worksheet_Change(ByVal Target As Range)
CommandButton1.Caption = Range("D1")
If Range("D1") = "FACTURE" Then CommandButton1.BackColor = RGB(255, 0, 0)
If Range("D1") = "DEVIS" Then CommandButton1.BackColor = RGB(200, 0, 0)
End Sub
ou encore comme cela
Private Sub Worksheet_Change(ByVal Target As Range)
CommandButton1.Caption = Range("D1")
If Range("D1") = "FACTURE" Then CommandButton1.BackColor = &HFF&
If Range("D1") = "DEVIS" Then CommandButton1.BackColor = &HC8&
End Sub
A+
Mike-31
Une période d'échec est un moment rêvé pour semer les graines du savoir.
Comme cela
Private Sub Worksheet_Change(ByVal Target As Range)
CommandButton1.Caption = Range("D1")
If Range("D1") = "FACTURE" Then CommandButton1.BackColor = RGB(255, 0, 0)
If Range("D1") = "DEVIS" Then CommandButton1.BackColor = RGB(200, 0, 0)
End Sub
ou encore comme cela
Private Sub Worksheet_Change(ByVal Target As Range)
CommandButton1.Caption = Range("D1")
If Range("D1") = "FACTURE" Then CommandButton1.BackColor = &HFF&
If Range("D1") = "DEVIS" Then CommandButton1.BackColor = &HC8&
End Sub
A+
Mike-31
Une période d'échec est un moment rêvé pour semer les graines du savoir.