Thread: Refresh timeout across WAN?
03-02-04, 06:14 #1Registered User
- Join Date
- Mar 2004
Unanswered: Refresh timeout across WAN?
Ive not used VB before. I've simple app that takes a date from a text field, builds a SQL for the datacontrol, refreshes to bring back data from a foxpro file and populates some bound controls.
Works like a dream in this building on the network the .dbf is on, the retrieval taking a few seconds.
When I plug the laptop in over the road into the WAN , the refresh times out after 2 minutes ish.
The properties of data4 I have set as
Connect Access (VB seems to ignore this when ODBC is chosen)
Databasename mydb (my VFP ODBC onnection, )
RecordSource (initially left blank )
sqltext = " select eq.EQP_TYPE,eq.SERIAL_NO,eq.DATE_L_SVC ....
Data4.RecordSource = sqltext
I've tried setting the querytimeout property in the registry to both large values and to 0 but with no change. But if the refresh time is > two minutes the app will be unusable anyway.
My ODBC setup for 'mydb' is using the Microsoft Visual Foxpro driver free tables. This ODBC works across the WAN when using either EXCEL(MSQUERY) or PowerBuilder, using the same SQL select.
When using a datacontrol set to 'ODBC' I presume VB still uses the Jet SQL engine. The eq. table has about 20,000 rows.
Being new to VB I'm unsure whether it is a service pack level issue or
whether I set something up in an odd way or ...
Last edited by Colin Delve; 03-02-04 at 07:44.
03-06-04, 10:04 #2Registered User
- Join Date
- Jan 2004
Re: Refresh timeout across WAN?
Is there a possibility to use ADO instead?
Here is a sample Connection String to connect to access:
"Provider=Microsoft.Jet.OLEDB.4.0;User ID=Admin;Data Source=C:\Test.mdb;Persist Security Info=False"
Change the CommandTimeout property to whatever number you like
Connection.CommandTimeout = 120
Connect your recordset to this connection object.In abundance of water only the fool is thirsty. Bob Marley.