473,485 Members | 1,479 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Slow response Autocomplete

Ant
Hi,
I'm using the text changed event of as text box to display a datagrid of
search results dynamically. (The classic 'gets more specific the more you
type in' scenario ).

I find when I first start the app & type in something into the text box, it
stalls & won't display the text you've typed in. After a short while, the
text appears & the results are loaded into the data grid. After the first
time, it works perfectly; loading data in as you type. (i.e. Type in A, you
get all rows beginning with A, type in Ax, you get fewer rows etc. ).
Why would it be so slow first time but ok after that? It's always re
instantiating the same class to do it. Has this got something to do with
memory caching & if so, how can I fix this so it works fast first time?

Hope that's a clear explanation...

Thanks for any ideas in advance.
Ant
Feb 8 '06 #1
3 2695
Hi Ant,
where are you storing your information, inside a database? If so then it
could be slow to begin with because the first time you try to connect to he
DB a connection will be made, which is an intensive process, after that the
connections will be pooled, so obtaining a connection to the DB is very fast.

Mark Dawson
http://www.markdawson.org

"Ant" wrote:
Hi,
I'm using the text changed event of as text box to display a datagrid of
search results dynamically. (The classic 'gets more specific the more you
type in' scenario ).

I find when I first start the app & type in something into the text box, it
stalls & won't display the text you've typed in. After a short while, the
text appears & the results are loaded into the data grid. After the first
time, it works perfectly; loading data in as you type. (i.e. Type in A, you
get all rows beginning with A, type in Ax, you get fewer rows etc. ).
Why would it be so slow first time but ok after that? It's always re
instantiating the same class to do it. Has this got something to do with
memory caching & if so, how can I fix this so it works fast first time?

Hope that's a clear explanation...

Thanks for any ideas in advance.
Ant

Feb 8 '06 #2
Ant
Hi Mark,

That sounds about right. It's pulling it from a db. What can I do to stop
this occuring? Should I open the connection on form load? Really not sure.

Thanks very much for your answer
Ant

"Mark R. Dawson" wrote:
Hi Ant,
where are you storing your information, inside a database? If so then it
could be slow to begin with because the first time you try to connect to he
DB a connection will be made, which is an intensive process, after that the
connections will be pooled, so obtaining a connection to the DB is very fast.

Mark Dawson
http://www.markdawson.org

"Ant" wrote:
Hi,
I'm using the text changed event of as text box to display a datagrid of
search results dynamically. (The classic 'gets more specific the more you
type in' scenario ).

I find when I first start the app & type in something into the text box, it
stalls & won't display the text you've typed in. After a short while, the
text appears & the results are loaded into the data grid. After the first
time, it works perfectly; loading data in as you type. (i.e. Type in A, you
get all rows beginning with A, type in Ax, you get fewer rows etc. ).
Why would it be so slow first time but ok after that? It's always re
instantiating the same class to do it. Has this got something to do with
memory caching & if so, how can I fix this so it works fast first time?

Hope that's a clear explanation...

Thanks for any ideas in advance.
Ant

Feb 8 '06 #3
Hi Ant,
like you mentioned you could just ping the database, i.e. call a stored
procedure, on the load of the form so that you establish a connection, then
you will not get the delay once you try to do the autocomplete functionality.

Mark.
"Ant" wrote:
Hi Mark,

That sounds about right. It's pulling it from a db. What can I do to stop
this occuring? Should I open the connection on form load? Really not sure.

Thanks very much for your answer
Ant

"Mark R. Dawson" wrote:
Hi Ant,
where are you storing your information, inside a database? If so then it
could be slow to begin with because the first time you try to connect to he
DB a connection will be made, which is an intensive process, after that the
connections will be pooled, so obtaining a connection to the DB is very fast.

Mark Dawson
http://www.markdawson.org

"Ant" wrote:
Hi,
I'm using the text changed event of as text box to display a datagrid of
search results dynamically. (The classic 'gets more specific the more you
type in' scenario ).

I find when I first start the app & type in something into the text box, it
stalls & won't display the text you've typed in. After a short while, the
text appears & the results are loaded into the data grid. After the first
time, it works perfectly; loading data in as you type. (i.e. Type in A, you
get all rows beginning with A, type in Ax, you get fewer rows etc. ).
Why would it be so slow first time but ok after that? It's always re
instantiating the same class to do it. Has this got something to do with
memory caching & if so, how can I fix this so it works fast first time?

Hope that's a clear explanation...

Thanks for any ideas in advance.
Ant

Feb 8 '06 #4

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

Similar topics

4
5239
by: bc | last post by:
Hi, Is it possible to detect if the IE autocomplete function in a current context such as a textbox is activated (ie. dropdown with previously entered info is visible)? Problem: I use a script...
40
10839
by: Alex | last post by:
Hello, does anybody know how to turn off the autocomplete feature for a certain text field? I am aware of the "autocomplete" attribute, but I have seen other implementions achieving it...
2
4492
by: Mrinal Kamboj | last post by:
Hi , Need to get some basic info regarding AutoComplete Attribute in COM+ . I am having a class with TransactionOption set to Required , now for this class , can i mark all the methods with...
1
1750
by: thubba2000 | last post by:
We have a web application developed using IBuySpy. In older versions, Autocomplete on all web forms works. In our latest version, it stopped working on all clients. I have gone through all the...
1
5171
by: rbg.net | last post by:
I know that there is a autocomplete property for the HTML "INPUT type=text" control which if set to OFF, disables autocomplete of the input textbox (doesn't remember previously entered values) ...
8
5725
by: nil | last post by:
Hello all, It's urgent... i want to add autocomplete textbox facility in my application like google. as you type it suggests option to the user..i want the same kind of facility...i know i...
1
3821
by: wkerplunk | last post by:
Below is what I have build with several different languages. It works great but I need help, I am stuck. When you click on an item in the dropdown autocomplete div it does a mousedown function...
2
2482
by: gnomee2 | last post by:
Hello Everyone, I have a strange problem that I cannot seem to solve. I have two server running Windows 2003 MSSQL on one IIS on the other. Out of the blue I have slow queries that cause asp...
3
2109
by: John | last post by:
Hi I have replaced an ms access app with its vb.net version at a client site. Now the clients keeps complaining about how slow the app response is. The complains they have are for example when...
0
7090
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6960
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7161
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6825
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5418
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4857
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3058
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3063
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
247
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.