Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP and lost network connection
Message
From
24/08/2000 16:44:12
 
 
To
23/08/2000 16:52:38
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00408498
Message ID:
00409002
Views:
61
>I have a VFP EXE on a network drive (NT 4 server and clients). The DBF it accesses is located in the same directory. We get seemingly random network interruptions which cause VFP to return "Error Reading File". I don't know if these errors have something to do with the way I have the app setup. If I can't find the source of these errors, I would at least like to exit the application gracefully after these errors occur. Even though my error handler has a QUIT (also tried CANCEL) statement, VFP refuses to quit and the users have to use the windows task manager to exit. Anyone have any ideas ?

Network connection errors can be caused by bad hardware, an overloaded server, power management features, running multiple network protocols on the same adapter and other things not related to your application. I had the same problem on some Novell networks that had been converted to Windows NT using TCP/IP as a protocol.

The problem with this error is that when it occurs, FoxPro seems to lose the handle to all open files and the only solution is to close tables then reopen them.

To duplicate this error, disconnect your network cable while your app is running.

My fix was to change the app to start PINGing the network card, local computer, default gateway and file server before critical disk read/writes. The error that is returned from a failed PING can be trapped and the app can gracefully shutdown, although a slight pause may be noticed when Fox attempts to close a table that is on a broken network connection. Note that this only works for TCP/IP networks.

I used NBTSTAT.EXE and IPCONFIG.EXE to determine the IP addresses that are being used.
Previous
Reply
Map
View

Click here to load this message in the networking platform