When i run the Code below, they will keep prompting me that my email does not exist whenever i click 1 letter in. how do i make it prompt me only after i finished typing in the textbox?
Code:
Private Sub EmailForget_Change()
Dim r1 As Range
Dim n1 As Long
Dim NextRow1 As Long
Application.ScreenUpdating = False
Sheets("Login Details").Select
NextRow1 = Application.WorksheetFunction.CountA(Range("A:A")) + 1
Set r1 = Range(Cells(2, 1), Cells(NextRow1, 1))
For n1 = 2 To r1.Rows.Count
If Trim(EmailForget.Value) = Trim(Cells(n1, 1).Value) Then
SecurityQnForget.Value = Trim(Cells(n1, 10).Value)
End If
Next n1
If Trim(EmailForget.Value) <> Trim(Cells(n1, 1).Value) Then
MsgBox "Your email does not exist.", vbCritical
End If