Modification d'une macro

condors.s

XLDnaute Occasionnel
Bonjour,
Sur la macro suivante, je voudrais change le "color index 38" par la palette de couleur suivante : RVB 79;45;127

Comment est ce que je peux faire ca?
Merci

Code:
Sub MacroMEFCondor()
Dim Montableau As Range
Dim NbLigne As Integer

Set Montableau = Selection.CurrentRegion
NbLigne = Montableau.Rows.Count

'tout le tableau
'----------------
With Montableau
'Motifs
With .Interior
.ColorIndex = 2
.Pattern = xlSolid
End With
'Police
With .Font
.Name = "Arial"
.Size = 8
End With
End With

'1ere ligne du tableau
'----------------------
With Montableau.Rows(1)
'Police
With .Font
.Name = "Arial"
.Size = 8
.Bold = True
.ColorIndex = 38
End With
'Bordures
With .Borders(xlEdgeTop)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
End With

'2eme ligne du tableau
'----------------------
With Montableau.Rows(2)
'Police
With .Font
.Name = "Arial"
.Size = 8
.Bold = True
End With
End With

'3eme ligne du tableau
'----------------------
With Montableau.Rows(3)
'Police
With .Font
.Name = "Arial"
.Size = 8
.Bold = True
.ColorIndex = 38
End With
'Bordures
With .Borders(xlEdgeTop)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
End With

'Dernière ligne du tableau
'----------------------
With Montableau.Rows(NbLigne)
'Police
With .Font
.Name = "Arial"
.Size = 8
.ColorIndex = 38
End With
'Bordures
With .Borders(xlEdgeTop)
.LineStyle = xlDash
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With .Borders(xlEdgeBottom)
.LineStyle = xlDash
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
End With

End Sub
Code:
 

Discussions similaires

Statistiques des forums

Discussions
312 519
Messages
2 089 244
Membres
104 076
dernier inscrit
Jérèmalo