Results 1 to 3 of 3

Thread: DataSearch

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2000
    Posts
    14

    Post

    I currently have a program that can write and read from a database using a series of text boxes. When an item number is entered and tap press it will check to see if that number is in the database and fill the remaining fields. If the number is not in the database the next textbox is description. I would like to program to search each time a letter is typed in the description and find the closest match. Like in programs such as quicken.

    Example:

    user types "a"
    description shows "Access Software"
    user adds a "x"
    description shows "Axies Mapmaker"

    any ideas on how to code this?

  2. #2
    Addicted Member
    Join Date
    Oct 1999
    Posts
    253

    Post

    Use the Change event of the Textbox and search the database using a query of this template:

    SELECT * FROM DB WHERE Description Like TextBox1.Text & "*".

    If you are using ADO, replace the last "*" with a "%"

    Good Luck!!!

  3. #3

    Thread Starter
    New Member
    Join Date
    Jan 2000
    Posts
    14

    Post

    I tried using a bit of code but it gave me an error at the first *. Do you have any suggestions to help with that? It says it's looking for a case statment there.

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