<de*@cornerstoneapplications.comwrote
Several years ago I developed an Access 97 runtime application. I
have rewritten this application using Visual Basic 6 with an Access
2003 database. When I run the VB application with the database on the
same PC, the performance is good. When I move the database to a
different PC on my two PC network, the performance is slow. This is
not the case with the original Access 97 application; it performs fast
regardless of where the database is located.
Does anyone have a idea of why the vb application performance would be
so much worse when the database in on a different PC? Any suggestions
would be appreciated.
Are you using ADO or DAO?
I ask because, if the former, someone else is going to have to try to help
because I am not familiar with ADO, ADODB, and OLEdb performance solutions;
but if the latter, then there are lots of documented "tricks" for Access
that can also apply to VB6... see MVP Tony Toews' site,
http://www.granite.ab.ca/accsmstr.htm for the Access version.
Keeping the database and a connection Open is the first "trick" to try.
The data control in VB does not work as smoothly as bound Forms in Access.
Most VB-with-database applications are implemented with unbound Forms.
Opening entire Tables or Queries with all the records from the underlying
Table does not enhance performance -- it's amazine how often most business
applications either need only one Record, if it exists, or none, if it
doesn't.
Larry Linson
Microsoft Access MVP