Option Explicit
Sub TEST()
Dim Brr, V, Y, N&, i&, T1$, T3$, T4$, T6$, TT1$, xR As Range
Set Y = CreateObject("Scripting.Dictionary")
Set xR = Range([G1], Cells(Rows.Count, "A").End(xlUp)): Brr = xR
For i = 2 To UBound(Brr)
T1 = Brr(i, 1): T3 = Brr(i, 3): T4 = Brr(i, 4): T6 = Brr(i, 6)
TT1 = T1 & "|" & T3 & "|" & Split(T4 & "-", "-")(1)
If Y.Exists(TT1) = Empty Then
Set Y(TT1) = Cells(i, 7): Y(TT1 & "單價") = Brr(i, 6)
ElseIf Brr(i, 6) <> Y(TT1 & "單價") Then
Set Y(TT1) = Union(Y(TT1), Cells(i, 7)): Y(TT1 & "單價") = "|"
End If
Next
xR.Offset(1, 6).ClearContents
For Each V In Y.items
If IsArray(V) Then N = N + 1: V.Value = "A" & N
Next
Set Y = Nothing: Set xR = Nothing: Erase Brr
End Sub