Daha önce Evren Gizlen kullanıcı isimli arkadaşın verdiği kodu uyarlamak istedim ama bir hata oldu bu formülde hata nerede acep arkadaşlar?
Sub Aktar()
Dim i As Long, sut As String, sat1 As Long, sat2 As Long
Sheets("TASIMA PROGRAMI").Select
Range("AA2:AD655536").ClearContents
Application.ScreenUpdating = False
sat1 = Cells(65536, "W").End(xlUp).Row
For i = 2 To sat1
If Cells(i, "Z").Value = "T.M" Then sut = "AA"
If Cells(i, "Z").Value = "FEN" Then sut = "AB"
If Cells(i, "Z").Value = "MAT" Then sut = "AC"
If Cells(i, "Z").Value = "SERBEST" Then sut = "AD"
sat2 = Cells(655536, sut).End(xlUp).Row + 2
Cells(sat2, sut).Value = Cells(i, "W").Value & " " & Cells(i, "X").Value
sat2 = sat2 + 1
Next i
Application.ScreenUpdating = True
MsgBox "Gruplama tamamlanmıştır." & vbLf & _
"www..com", vbOKOnly + vbInformation, "OK"
End Sub
Sub Aktar()
Dim i As Long, sut As String, sat1 As Long, sat2 As Long
Sheets("TASIMA PROGRAMI").Select
Range("AA2:AD655536").ClearContents
Application.ScreenUpdating = False
sat1 = Cells(65536, "W").End(xlUp).Row
For i = 2 To sat1
If Cells(i, "Z").Value = "T.M" Then sut = "AA"
If Cells(i, "Z").Value = "FEN" Then sut = "AB"
If Cells(i, "Z").Value = "MAT" Then sut = "AC"
If Cells(i, "Z").Value = "SERBEST" Then sut = "AD"
sat2 = Cells(655536, sut).End(xlUp).Row + 2
Cells(sat2, sut).Value = Cells(i, "W").Value & " " & Cells(i, "X").Value
sat2 = sat2 + 1
Next i
Application.ScreenUpdating = True
MsgBox "Gruplama tamamlanmıştır." & vbLf & _
"www..com", vbOKOnly + vbInformation, "OK"
End Sub
Ekli dosyalar
-
42.5 KB Görüntüleme: 12