473,320 Members | 1,810 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Change AutoComplete to "full text" search?

Is it possible to change the autocomplete behaviour to search for the word
instead of just checking for the prefix?

For example, if I have the following items:

Big Mac
Quarter Pounder
Cheeseburger

and someone types: Pounder, it should display "Quarter Pounder"?

Thanks!

--
sp**********@rogers.com (Do not e-mail)
Apr 4 '08 #1
7 3632
On Apr 4, 2:20 pm, Spam Catcher <spamhoney...@rogers.comwrote:
Is it possible to change the autocomplete behaviour to search for the word
instead of just checking for the prefix?

For example, if I have the following items:

Big Mac
Quarter Pounder
Cheeseburger

and someone types: Pounder, it should display "Quarter Pounder"?

Thanks!

--
spamhoney...@rogers.com (Do not e-mail)
For instance, try this:

Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal
e As System.EventArgs) Handles TextBox1.TextChanged
If TextBox1.Text = "Pounder" Then
TextBox1.Text = "Quarter Pounder"
End If
End Sub
Apr 4 '08 #2
kimiraikkonen <ki*************@gmail.comwrote in news:81162e90-2bcd-4d62-
87***************@b5g2000pri.googlegroups.com:
For instance, try this:

Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal
e As System.EventArgs) Handles TextBox1.TextChanged
If TextBox1.Text = "Pounder" Then
TextBox1.Text = "Quarter Pounder"
End If
End Sub
How is that going to help me in an autocomplete situation?

--
sp**********@rogers.com (Do not e-mail)
Apr 4 '08 #3
On Apr 4, 7:26*pm, Spam Catcher <spamhoney...@rogers.comwrote:
kimiraikkonen <kimiraikkone...@gmail.comwrote in news:81162e90-2bcd-4d62-
8773-54fe107c4...@b5g2000pri.googlegroups.com:
For instance, try this:
Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal
e As System.EventArgs) Handles TextBox1.TextChanged
If TextBox1.Text = "Pounder" Then
TextBox1.Text = "Quarter Pounder"
End If
End Sub

How is that going to help me in an autocomplete situation?

--
spamhoney...@rogers.com (Do not e-mail)
I know it's not directly related to AutoComplete property but this can
give you an urgent solution that makes text field as you wish if typer
writes "Pounder" then textbox becomes "Ouarter Pounder" because of
textbox's text_changed event, i hope you tried it.
Apr 4 '08 #4
kimiraikkonen <ki*************@gmail.comwrote in news:0ecc162b-f2b4-4740-
b7***************@p39g2000prm.googlegroups.com:
I know it's not directly related to AutoComplete property but this can
give you an urgent solution that makes text field as you wish if typer
writes "Pounder" then textbox becomes "Ouarter Pounder" because of
textbox's text_changed event, i hope you tried it.
Unfortunately its not what I'm really looking for - I would like to have
the autocomplete list populated with suggestions like what Google Suggests
does.

If I only handle the TextChange event ... it'll be too much of a kudlge to
be rewriting the user's input on the fly? I rather be able to display the
suggestions in the autocomplete portion of the control.

But, thanks for the suggestion!

--
sp**********@rogers.com (Do not e-mail)
Apr 5 '08 #5

"Spam Catcher" <sp**********@rogers.comwrote in message
news:Xn**********************************@127.0.0. 1...
kimiraikkonen <ki*************@gmail.comwrote in
news:0ecc162b-f2b4-4740-
b7***************@p39g2000prm.googlegroups.com:
>I know it's not directly related to AutoComplete property but this can
give you an urgent solution that makes text field as you wish if typer
writes "Pounder" then textbox becomes "Ouarter Pounder" because of
textbox's text_changed event, i hope you tried it.

Unfortunately its not what I'm really looking for - I would like to have
the autocomplete list populated with suggestions like what Google Suggests
does.

If I only handle the TextChange event ... it'll be too much of a kudlge to
be rewriting the user's input on the fly? I rather be able to display the
suggestions in the autocomplete portion of the control.

But, thanks for the suggestion!

--
sp**********@rogers.com (Do not e-mail)

Textbox has its own Autocomplete functionallity.

As an example:

Me.TextBox1.AutoCompleteCustomSource.AddRange(New String() {"One", "Two",
"Three"})
Me.TextBox1.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.Suggest
Me.TextBox1.AutoCompleteSource =
System.Windows.Forms.AutoCompleteSource.CustomSour ce

The AutoCompleteCustomSource can be populated in pretty much any way you
want as long as it is an array of strings. Get it from database or where
ever.

Hope this is what you are looking for
Lloyd Sheen

Apr 5 '08 #6
"Lloyd Sheen" <a@b.cwrote in
news:OO**************@TK2MSFTNGP05.phx.gbl:
Textbox has its own Autocomplete functionallity.

As an example:

Me.TextBox1.AutoCompleteCustomSource.AddRange(New String() {"One",
"Two", "Three"})
Me.TextBox1.AutoCompleteMode =
System.Windows.Forms.AutoCompleteMode.Suggest
Me.TextBox1.AutoCompleteSource =
System.Windows.Forms.AutoCompleteSource.CustomSour ce

The AutoCompleteCustomSource can be populated in pretty much any way
you want as long as it is an array of strings. Get it from database
or where ever.

Hope this is what you are looking for
Yes, I know - but AutoComplete only search the PREFIX of the entries.

As you see in my example, if you populate the autocomplete source with:

Big Mac
Quarter Pounder
Cheeseburger

and someone types in Pounder... it won't display Quarter Pounder as a
suggestion...

That's my problem - not how to populate the autocomplete datasource.

I want to override/rewire the AutoComplete functionality in Winform
Controls - if someone can point me in the right direction, that'll be
great!

Thanks.

--
sp**********@rogers.com (Do not e-mail)
Apr 5 '08 #7
"Lloyd Sheen" <a@b.cwrote in
news:uE**************@TK2MSFTNGP05.phx.gbl:
>
"Lloyd Sheen" <a@b.cwrote in message
news:%2****************@TK2MSFTNGP03.phx.gbl...
>>
"Spam Catcher" <sp**********@rogers.comwrote in message
news:Xn**********************************@127.0.0 .1...
>>"Lloyd Sheen" <a@b.cwrote in
news:OO**************@TK2MSFTNGP05.phx.gbl:

Textbox has its own Autocomplete functionallity.

As an example:

Me.TextBox1.AutoCompleteCustomSource.AddRange(N ew String() {"One",
"Two", "Three"})
Me.TextBox1.AutoCompleteMode =
System.Windows.Forms.AutoCompleteMode.Suggest
Me.TextBox1.AutoCompleteSource =
System.Windows.Forms.AutoCompleteSource.CustomS ource

The AutoCompleteCustomSource can be populated in pretty much any
way you want as long as it is an array of strings. Get it from
database or where ever.

Hope this is what you are looking for

Yes, I know - but AutoComplete only search the PREFIX of the
entries.

As you see in my example, if you populate the autocomplete source
with:

Big Mac
Quarter Pounder
Cheeseburger

and someone types in Pounder... it won't display Quarter Pounder as
a suggestion...

That's my problem - not how to populate the autocomplete datasource.

I want to override/rewire the AutoComplete functionality in Winform
Controls - if someone can point me in the right direction, that'll
be great!

Thanks.

--
sp**********@rogers.com (Do not e-mail)


Ok try this.

Hmmm... Intersting, I'll give it a try.

Thanks!
--
sp**********@rogers.com (Do not e-mail)
Apr 6 '08 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: Jay Chan | last post by:
I keep getting the following error message when I run a serie of SQL commands: Server: Msg 9002, Level 17, State 6, Line 15 The log file for database 'tempdb' is full. Back up the transaction...
0
by: Robert Oschler | last post by:
I have a database table with a field that is indexed as a "full-text" search, since I want the capabiity. However, I also want the ability to quickly retrieve records from that table that are ins...
26
by: Michel Rouzic | last post by:
I have a binary file used to store the values of variables in order to use them again. I easily know whether the file exists or not, but the problem is, in case the program has been earlier...
2
by: Samuel R. Neff | last post by:
What options are available for doing full-text searches of database data without using a database-specific full-text engine? The only option I've found is Google's Search Appliance but it's an...
3
by: Olivier Verdin | last post by:
Hi, I am developing a multi-language application in ASP.NET in c#. I am using a file field html control to upload an image. I would like to change the text on the button "browse" that comes...
1
hpbutterbeer
by: hpbutterbeer | last post by:
We have a Machine Project and my brain is currently in a clouded state. Sorry, I'm just a beginner in C Programming... Text twist is a windows game whose main objective is to form words out of the...
8
by: Freddy Coal | last post by:
Hi, I would like make a search and replace in a file, for that I need get the text in a textbox, but I need recognyze literally characters of the user like a commands, for example: The chain of...
10
by: Prisoner at War | last post by:
Besides resorting to images. Say, a headline tilted at 30° or something. TIA!
1
by: avipeter | last post by:
Hi to all. I am so new in this, I don't know how to finish my homework-question. I have to go to bed now ánd need to find an answer a.s.a.p. Who is willing to help this Dutch boy? I have to...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.