Sub Sadelestir()
For x = 2 To [a65536].End(3).Row
Say = WorksheetFunction.CountIf(Range("j2:j" & [j65536].End(3).Row + 1), Cells(x, "a"))
If Say = 0 Then
tpl = 0
Set Aralik = Range("a2:a" & [a65536].End(3).Row)
Set Bul = Aralik.Find(Cells(x, "a"), LookIn:=xlValues, lookat:=xlWhole)
If Not Bul Is Nothing Then
Adres = Bul.Address
Do
tpl = tpl + Val(Cells(Bul.Row, "b"))
Set Bul = Aralik.FindNext(Bul)
Loop While Not Bul Is Nothing And Bul.Address <> Adres
End If
Sat = [j65536].End(3).Row + 1
Cells(Sat, "j") = Cells(x, "a")
Cells(Sat, "k") = tpl
End If
Next
End Sub
Burda tamsayılarda problem olmuyorda toplarken, adetler virgüllü olursa virgül sonrasını toplarken hesaba katmıyor sadece tamsayı taraflarını topluyor.Toplarken virgüllü tarafıda hesaba katmalı
For x = 2 To [a65536].End(3).Row
Say = WorksheetFunction.CountIf(Range("j2:j" & [j65536].End(3).Row + 1), Cells(x, "a"))
If Say = 0 Then
tpl = 0
Set Aralik = Range("a2:a" & [a65536].End(3).Row)
Set Bul = Aralik.Find(Cells(x, "a"), LookIn:=xlValues, lookat:=xlWhole)
If Not Bul Is Nothing Then
Adres = Bul.Address
Do
tpl = tpl + Val(Cells(Bul.Row, "b"))
Set Bul = Aralik.FindNext(Bul)
Loop While Not Bul Is Nothing And Bul.Address <> Adres
End If
Sat = [j65536].End(3).Row + 1
Cells(Sat, "j") = Cells(x, "a")
Cells(Sat, "k") = tpl
End If
Next
End Sub
Burda tamsayılarda problem olmuyorda toplarken, adetler virgüllü olursa virgül sonrasını toplarken hesaba katmıyor sadece tamsayı taraflarını topluyor.Toplarken virgüllü tarafıda hesaba katmalı
