Results 1 to 2 of 2

Thread: saving unique records using textbox

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Feb 2001
    Location
    bkk
    Posts
    224
    hi
    i have a more than 10 textboxes, while at each text box i have to check the record which is already exists or not, iam useing access as backend and ado control, pls help
    cheers
    [email protected]

  2. #2
    Addicted Member CoMMiE's Avatar
    Join Date
    Jul 2000
    Location
    Malaysia, Kuala Lumpur
    Posts
    179
    This is how i did it:

    Private Sub Text1_LostFocus()


    'verify there is no duplicates name

    Adodc1.RecordSource = "Select name from employeedetails where name='" & Text1.Text & "'"
    Adodc1.Refresh
    If Text21.Text = vbNullString Then
    Else

    If Text21.Text = Text1.Text Then
    MsgBox "It is already in use,please try another one"
    Text1.Text = vbNullString
    Text1.SetFocus


    Else
    End If

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width