Bonjour
essaye cette macro
Sub Aléa()
Dim c As Double
Dim l As Double
Dim i As Integer
i = 1
c = 0
l = 0
For c = 1 To 5
For l = 1 To 8
Cells(l, c).Interior.ColorIndex = 0
Next l
Next c
While i <= 6
Randomize
c = Rnd
c = c * 5
l = Rnd
l = l * 8
If l > 1 And c > 1 Then
If Cells(l, c).Interior.ColorIndex <> 36 Then
Cells(l, c).Interior.ColorIndex = 36
i = i + 1
End If
End If
Wend
End Sub
cordialement