Hello,

I have a program that connects remotely to a mySql database server. On form load, I have the connection made to display information on the main screen.

In my cPanel (where I host my data) I *must* whitelist the IP address from the computer that is connecting remotely to the database in order to get past my host's firewall.

I have an error handler that will step in if there is a problem with connecting to my database on form load. On error, a msgbox alerts the user that there is a connection problem, then exit sub.... so then the rest of the program still loads.

Here is what I notice:

If the internet connection itself is down, the error handler works fast, and the msgbox appears right away.

Sometimes my IP address changes from my internet service provider, and it will have to be relisted to the host's firewall in order to connect properly. If the whitelisted IP is dropped, the error handler takes forever to show the msgbox: my application takes a long time to load then.

Other forms that use connections to the database also take forever, and sometimes my application will temporarily freeze until the msgbox appears finally.

What can be done about this? Any ideas? Thanks.