- Katılım
- 13 Mayıs 2005
- Mesajlar
- 761
- Excel Vers. ve Dili
- 2010 Türkçe
Kullanılan İzinler sayfasına e girdiğim verilere göre Rapor-Kişi sayfasında de işlem yapıyorum. Rapor-Kişi sayfasındaki J1 hücresi 0 sıfırın altına düşerse uyarı alabilirmiyim. Kullanılan İzinler sayfası ile bağıntılı çalışıyor.
Kullandığım kod bu buna ilave yapmam lazım.
Kullandığım kod bu buna ilave yapmam lazım.
Kod:
Private Sub Worksheet_Change(ByVal Target As Range)
If Selection.Count > 1 Then Exit Sub
If Intersect(Target, Range("D:G")) Is Nothing Then Exit Sub
satir = Target.Row
sutun = Target.Column
sonsatira = Cells(Rows.Count, "D").End(3).Row
sonsatirb = Cells(Rows.Count, "G").End(3).Row
If Target.Column = 4 Then
If Target.Row = sonsatira Then
Worksheets("Rapor-Kişi").Range("D1") = Target
End If
End If
If sonsatira > sonsatirb Then SonSatir = sonsatira Else SonSatir = sonsatirb
Say = 0
For i = 1 To SonSatir
veria = Cells(i, "D").Value
verib = Cells(i, "G").Value
If veria = Cells(satir, "D").Value And verib = Cells(satir, "G").Value Then Say = Say + 1
Next i
If Say > 1 Then
MsgBox (veria & " ve " & verib & " Mükerrer girildi.")
Application.EnableEvents = False
Cells(satir, "D").Value = ""
Cells(satir, "G").Value = ""
Application.EnableEvents = True
End If
End Sub
Son düzenleme:
