Word suggestions - how to?

I am currently working on a program where the user can type in the last name of a customer to pull up his/her account info etc...what i wanna add (and also am curious as to how to do it) is the ability for it to suggest last names (from a list of last names that exist in the database) if the user misspells the last name and no results are found...kinda like ms word where you misspell a word and it gives you suggestions, but i have no idea on how to go about doing this, and i think this would be an interested little project and something i can learn from :)

thanks


Answer this question

Word suggestions - how to?

  • HungSolo

    Hello I have Windows XP. I recently I upgraded to explorer 7. Now when I use search box a box comes up asking - Do I want to use auto complete. I say no as others use this computer. Yesterday I clicked yes by mistake. Now when I start typing in search box a drop down box shows previous searches. I do not want this, when I visit password protected sites it also gives details in drop down box. How do I disable this auto complete permanently. I do hope you can help. I have read other auto complete requests. They do not tell me wht i ahve to do ro remove

    Kind regards derf1934


  • RajOnline

    I did something similar to what you are trying, but it was in C++, and a while back ago.  I had a drop down box, where I let the user type in what he remembered of the name.  He would then press F5, and it would perform a TOP 20 %Like% SQL search, and display the names sorted alpha, from which the user could select from.  and / or - If the user remembered the whole name, he could type it in, and Viola.

    I'm sure the same type of thing could be performed in VB.


  • Snouto

    well, having 10,000+ customers in the database and adding customers on the fly as needed, i dunno if that'd be the best solution...loading all the customer names into the customsource string collection....

  • Amith

    Did you try looking in the Help for the Control Properties:

    AutoCompleteCustomSource

    AutoCompleteMode

    AutoCompleteSource

    I think this might be what you are trying to get at.

     

    Matt


  • MattO2

    hi,

    i think it could happend, mainly in the names suggestion programs, it depends on the first 3 or 4 letters in the name so you can take the name that the user entered and take substring(2, 3 or 4 letters) from it and search your database by like% and get the top 5 results and put it in a lable or what ever you want

     

    hope it was helpfull



  • Vu Tran

    hi fox
    that would work but that is if the user entered the name coreectly, what im trying to do is the following:
    lets say a customers last name is "WILLIAMS" but the user types in "WILLAIMS"
    or the customers last name is "SCHULTS" but the customer types in "SHULTS" thinking thats how its spelled, but i want the program to suggest other last names that i could be

    thanks

  • Word suggestions - how to?