c# - How to make a "Real-Time Responsive"? -


i have textbox , datagridview. when user presses types words inside textbox, datagridview should show result db (bound datagridview)

question: how make textbox "on real response"?

i mean if type "hello", , during processing of inputting each letter textbox, each time have new search, ui form must dead because there many requests db. know can use threads, want there's mechanism can allow me cancel or accept "search db , bind datagridview".

in detail, is:

each time when change textbox's value, there comes request value textbox , search db, , previous textbox's value can cancelled instead of doing previous search in background-thread, etc.

does .net framework have such mechanism now? or someone can suggest ideas cancelling previous query string searched or during searching process? can show me demo persudo codes

if want cancel previous query call cancel on dbcommand object executed query. why don't know already, given it's right there in documentation?

that said, tend use timer delay query short period. way, no query executed until user pauses typing.


Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -