sirkülasyon
Altın Üye
- Katılım
- 10 Temmuz 2012
- Mesajlar
- 2,532
- Excel Vers. ve Dili
- 2021 LTSC TR
- Altın Üyelik Bitiş Tarihi
- 18-06-2026
Kod:
Private Sub TextBox1_Exit(ByVal Cancel As MSForms.ReturnBoolean)
On Error Resume Next
If TCKimlikOnYazimKontrol(TextBox1.Text) = False Then
Me.TextBox1 = ""
'MsgBox "Hatalı T.C Kimlik No Girdiniz. Lütfen Kontrol Ederek Tekrar Deneyiniz !...", vbCritical
Cancel = True
Me.TextBox1.SetFocus
End If
If WorksheetFunction.CountIf(Sheets("KAYIT").Range("C2:C"), TextBox1.Value) > 0 Then
Dim k As Range
If TextBox1.Value = "" Then Exit Sub
Set k = Range("C2:C65536").Find(TextBox1.Value, , xlValues, xlWhole)
If Not k Is Nothing Then
k.Select
k.Value = TextBox1.Value
If WorksheetFunction.CountIf(Sheets("Kayıt").Range("C2:C"), TextBox1.Value) > 0 Then
Me.TextBox1.SetFocus
Cancel = True
Me.TextBox1 = Empty
Dim cevap As Integer
cevap = MsgBox(" MÜKERRER KAYIT Yapmaktasınız. Lütfen Kontrol Ediniz!...", vbNo + vbQuestion, "ONAY")
If cevap = vbNo Then
MsgBox "İşleminiz iptal edilmiştir."
Exit Sub
End If
End If
End If
End If
End Sub
İsteğim : Combobox1 değerine göre diğer sayfada da mükerrer kontrol yapabilsin.
Örnek : Combobox1 "İLK" ise KAYIT sayfasında, "İLK" dışında bir değer ise hem "Yeni Gelen" hem de "KAYIT" sayfasında mükerrer kontrol yapabilsin.
Yardımcı olabilir misiniz?