Ilino
XLDnaute Barbatruc
Bonsoir
Je voudrais savoir comment faire un rappel de texte dans des cellules fusionnées au lieu une cellule
Ci-dessous le code mais je n’arrive pas a le faire avec des cellules fusionnées
Private Sub Worksheet_Change(ByVal Target As Range)
'----------- Colonne C : Nom
If Not Intersect(Target, Range("c3")) Is Nothing Then
If Target = "" Then Target = "Nom"
If Target = "Nom" Then
Target.Font.Color = RGB(216, 216, 216)
Else
Target.Font.Color = RGB(0, 0, 0)
End If
End If
'----------- Colonne D : PréNom
If Not Intersect(Target, Range("d3")) Is Nothing Then
If Target = "" Then Target = "Prénom"
If Target = "Prénom" Then
Target.Font.Color = RGB(216, 216, 216)
Else
Target.Font.Color = RGB(0, 0, 0)
End If
End If
'----------- Colonne E : Fonction
If Not Intersect(Target, Range("e3")) Is Nothing Then
If Target = "" Then Target = "Fonction"
If Target = "Prénom" Then
Target.Font.Color = RGB(216, 216, 216)
Else
Target.Font.Color = RGB(0, 0, 0)
End If
End If
End Sub
NB : j'ai pris le fil de VALTER
merci
Je voudrais savoir comment faire un rappel de texte dans des cellules fusionnées au lieu une cellule
Ci-dessous le code mais je n’arrive pas a le faire avec des cellules fusionnées
Private Sub Worksheet_Change(ByVal Target As Range)
'----------- Colonne C : Nom
If Not Intersect(Target, Range("c3")) Is Nothing Then
If Target = "" Then Target = "Nom"
If Target = "Nom" Then
Target.Font.Color = RGB(216, 216, 216)
Else
Target.Font.Color = RGB(0, 0, 0)
End If
End If
'----------- Colonne D : PréNom
If Not Intersect(Target, Range("d3")) Is Nothing Then
If Target = "" Then Target = "Prénom"
If Target = "Prénom" Then
Target.Font.Color = RGB(216, 216, 216)
Else
Target.Font.Color = RGB(0, 0, 0)
End If
End If
'----------- Colonne E : Fonction
If Not Intersect(Target, Range("e3")) Is Nothing Then
If Target = "" Then Target = "Fonction"
If Target = "Prénom" Then
Target.Font.Color = RGB(216, 216, 216)
Else
Target.Font.Color = RGB(0, 0, 0)
End If
End If
End Sub
NB : j'ai pris le fil de VALTER
merci
Dernière édition: