+ Reply to Thread
Results 1 to 5 of 5

Keypress > database query > 'threading'

  1. #1
    Registered User
    Join Date
    11-09-2016
    Location
    London, England
    MS-Off Ver
    2010/2016
    Posts
    72

    Keypress > database query > 'threading'

    Hi,

    I have a UserForm with a textbox. When the value is 6 or more characters I want to run a query passing the value of this textbox and populate another textbox with the query result.

    This is all fine so far using Change event. My question is can I allow typing to continue seamlessly while it's doing the query? At the moment there is a delay with each keypress once the minimum 6 characters is reached.

    I know native VBA can't do multiple threading.

    Thanks

  2. #2
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Keypress > database query > 'threading'

    What's the database? A real one or Excel?

    If it's a real one, you don't need multi-threading, asynchronous ADO calls should be sufficient
    Last edited by Kyle123; 10-11-2019 at 12:05 PM.

  3. #3
    Registered User
    Join Date
    11-09-2016
    Location
    London, England
    MS-Off Ver
    2010/2016
    Posts
    72
    Quote Originally Posted by Kyle123 View Post
    What's the database? A real one or Excel?

    If it's a real one, you don't need multi-threading, asynchronous ADO calls should be sufficient
    Sorry - MS SQL Server

  4. #4
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Keypress > database query > 'threading'


  5. #5
    Registered User
    Join Date
    11-09-2016
    Location
    London, England
    MS-Off Ver
    2010/2016
    Posts
    72

    Re: Keypress > database query > 'threading'

    Please Login or Register  to view this content.
    Last edited by ldoodle; 10-11-2019 at 12:42 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] What's difference between a database query and a database table query?
    By sumdumgai in forum Excel General
    Replies: 5
    Last Post: 09-27-2012, 05:30 PM
  2. Database Query-possible to link a spreadsheet to a database
    By COYF in forum Access Tables & Databases
    Replies: 1
    Last Post: 03-04-2010, 09:37 AM
  3. Replies: 3
    Last Post: 08-14-2006, 05:10 PM
  4. Replies: 2
    Last Post: 03-08-2006, 04:45 PM
  5. Database Query-a query that reads data from MS Access
    By Osmar Mateus in forum Excel General
    Replies: 4
    Last Post: 01-29-2006, 04:10 PM
  6. Replies: 4
    Last Post: 11-29-2005, 09:44 AM
  7. COM and threading in VBA
    By Nick Palmer in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-27-2005, 09:05 PM
  8. [SOLVED] Threading Problem
    By ThisShouldBeEasy in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-08-2005, 09:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1