Macro : si cellule vide, sélectionner cette cellule
Résolu/Fermé
A voir également:
- Macro : si cellule vide, sélectionner cette cellule
- Macro word - Guide
- Macro logiciel - Télécharger - Organisation
- Telecharger macro convertir chiffre en lettre excel - Télécharger - Tableur
- Macro recorder - Télécharger - Confidentialité
- Macro souris ✓ - Forum Windows
1 réponse
Gyrus
Messages postés
3334
Date d'inscription
samedi 20 juillet 2013
Statut
Membre
Dernière intervention
9 décembre 2016
523
1 déc. 2015 à 12:47
1 déc. 2015 à 12:47
Bonjour,
Essaie comme cela
A+
Essaie comme cela
Sub Test()
Dim cellule As Range
Application.ScreenUpdating = False
For Each cellule In Range("A5:J700")
If cellule <> "" Then
With cellule
.Borders(xlDiagonalDown).LineStyle = xlNone
.Borders(xlDiagonalUp).LineStyle = xlNone
With .Borders(xlEdgeLeft)
.LineStyle = xlDouble
.Weight = xlThick
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeTop)
.LineStyle = xlDouble
.Weight = xlThick
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeBottom)
.LineStyle = xlDouble
.Weight = xlThick
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeRight)
.LineStyle = xlDouble
.Weight = xlThick
.ColorIndex = xlAutomatic
End With
End With
End If
Next
End Sub
A+
1 déc. 2015 à 13:34