• DİKKAT

    DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
    Altın Üyelik Hakkında Bilgi

Soru Formülsüz toplama işlemi

ümit bektas

Altın Üye
Katılım
12 Eylül 2021
Mesajlar
54
Excel Vers. ve Dili
Microsoft Office 2016 Türkçe
Merhaba,
aşağıdaki "sonuç" gibi vba nasıl toplama yaptıra bilirim


244447
 
Kod:
Sub topla()
    Dim lastRow As Long
    Dim i As Long
   
    lastRow = Cells(Rows.Count, "C").End(xlUp).Row
   
    For i = 2 To lastRow
        If Cells(i, "C").Value <> "" And Cells(i, "D").Value <> "" And Cells(i, "E").Value <> "" And Cells(i, "F").Value <> "" And Cells(i, "G").Value <> "" Then
            Cells(i, "G").Value = Cells(i, "C").Value - (Cells(i, "D").Value + Cells(i, "E").Value + Cells(i, "F").Value + Cells(i, "G").Value)
        End If
    Next i
End Sub
 
Kod:
Sub topla()
    Dim lastRow As Long
    Dim i As Long
  
    lastRow = Cells(Rows.Count, "C").End(xlUp).Row
  
    For i = 2 To lastRow
        If Cells(i, "C").Value <> "" And Cells(i, "D").Value <> "" And Cells(i, "E").Value <> "" And Cells(i, "F").Value <> "" And Cells(i, "G").Value <> "" Then
            Cells(i, "G").Value = Cells(i, "C").Value - (Cells(i, "D").Value + Cells(i, "E").Value + Cells(i, "F").Value + Cells(i, "G").Value)
        End If
    Next i
End Sub
Hocam kod çalışmıyor
 
Merhaba Arkadaşım,
Kod:
Sub topla()
    Dim lastRow As Long
    Dim i As Long
    
    lastRow = Cells(Rows.Count, "C").End(xlUp).Row
  
    For i = 2 To lastRow
            Cells(i, "G").Value = Cells(i, "C").Value - (Cells(i, "D").Value + Cells(i, "E").Value + Cells(i, "F").Value + Cells(i, "G").Value)
    Next i
End Sub
Bu haliyle deneyin
İyi çalışmalar
 
Merhaba Arkadaşım,
Kod:
Sub topla()
    Dim lastRow As Long
    Dim i As Long
   
    lastRow = Cells(Rows.Count, "C").End(xlUp).Row
 
    For i = 2 To lastRow
            Cells(i, "G").Value = Cells(i, "C").Value - (Cells(i, "D").Value + Cells(i, "E").Value + Cells(i, "F").Value + Cells(i, "G").Value)
    Next i
End Sub
Bu haliyle deneyin
İyi çalışmalar
Çok Teşekkür ederim İşimi gördü.
 
Geri
Üst