AddThis button
    Add Me    
Syndicate content

Ensure rendering happens in MS-Access

Reserve your domain name now!

Today I bumped in another problem: I want to show my user a message saying that I'm terribly busy looking for data in the database. Because I use ODBC with QuickBooks (QODBC to be precise), the system is somewhat slow. Therefore, it can take a little while and people just can't wait and they start clicking everywhere like crazy. That's a big problem...

Since I cannot close the form (i.e. the form searches and then renders the results on screen!), I decided to have a hidden Label with a message "Searching... Please Wait...". That message is to be shown by setting the Visible parameter of the label to True (I make sure it is false when the form is opened.)

So I tried...

  1. SearchLabel.Visible = True
  2. SQL = "SELECT ..."
  3. Display Results
  4. SearchLabel.Visible = False

This works, in theory. The problem, with this code, is that the label is shown AFTER the SQL code is executed.

The way to fix this would be to either pause for a little while (but that's a waste...) or ask Access to execute all the events, especially the event of showing the search label. The first solution requires a call to Sleep() which is not readily available in MS-Access. The second solution, which frankly I could not even remotely think would be possible is not only available, but it is dead easy with one very simple Application call: DoEvents

So right after setting the Visible parameter of the SearchLabel to True, call DoEvents and voila! You see that label immediately!

  1. SearchLabel.Visible = True
  2. DoEvents
  3. ... ' Do your work
  4. SearchLabel.Visible = False
Check this out!

Having problems maintaining your site index?
Each time you read a page you notice that some terms are missing for that page?
Or old terms that do not apply anymore are still being used there?

We have your solution: MO Auto add terms to automatically
add (and remove) terms from your Drupal website pages.

Syndicate content

You like this theme?
Get it now for your
Drupal v6.x website!
The White Theme

     

Terms of Site Index

Find the page/content you are looking for with our index.

  • application
  • date
  • dialog
  • gcc
  • GUID

    A GUID is a Globally Unique IDentifier. It is used by objects that need to run on any computer in the whole entire world. It is very likely that, once in a while, two people will generate the exact same GUID, although quite unlikely. Each computer has a network card now and that card serial number is often used as a starting point to define GUID on that computer. GUID were invented by Microsoft for their operating system.