Sub UnGroupe()
Dim a, d As New Dictionary, L As Long, Groupe As String, clé As String
a = Feuil3.Range("A2:D10") ' & Feuil3.Range("A65536").End(xlUp).Row)
produit = Feuil1.Range("C1:H1")
Entreprise = Feuil1.Range("C2:H2")
Feuil1.Range("J7:M10").ClearContents
Groupe = Feuil1.[C3]
For j = 1 To UBound(a, 1)
If a(j, 4) = Groupe Then d(a(j, 3) & "-" & a(j, 1)) = d(a(j, 3) & "-" & a(j, 1)) + a(j, 2)
Next
L = 6
With Feuil1
.Cells(7, "J") = Groupe
For Each clé In d.Keys 'Items
L = L + 1
.Cells(L, "K") = Mid(clé, 1, InStr(clé, "-") - 1) 'entreprise
.Cells(L, "L") = Mid(clé, InStr(clé, "-") + 1) 'produit
.Cells(L, "M") = d.Item(clé): .Cells(L, "M").NumberFormat = "0.00 €"
Next clé
End With
End Sub