Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error Reading file
Message
From
15/06/2005 17:21:09
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
14/06/2005 15:35:57
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 6
OS:
Windows 2000 SP4
Network:
Windows 2000 Pro
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01023245
Message ID:
01023724
Views:
15
>My application works on 2 PCs over the network. The database is located on one of them. On the second one from time to time the "Error Reading file" appears. It happens rearly, once or twice per week, but often enough to piss off the customer :-(
>
>It definately related to network troubles. But the application pulls the data from 4 TCP devices 5 times per second and does not loose the connections when the problem happens. Probably the network drops for split of a second. Just enough to screw the VFP up.
>
>Questions:
>1) How to get rid of "Error Reading file"?
>2) How to make VFP more stable on the network?

Fix the network. No other advice. Sometimes it's loose cable plugs, sometime it's the network card, sometimes it's a cable going too close to a source of electrical noise (welding, huge motors being turned on/off, x-ray machine - seen them all).

>3) Is it any way to recover after the "Error Reading file" without restarting the Application?

I thought not, but Arto's code seems to be the best answer to that that I saw so far.

One thing that I found that at least saves the tables from corruption, was to reopen the table(s) in another instance of Fox (this was in FPD2.6, mind you - haven't seen this error since), update a record and close the table. Nowadays, you could possibly do that within the same instance of the app - close the dbc, tablerevert() any buffers etc, then reopen the tables, do a little change, save, undo change, save. Having that done in a separate datasession would probably be even better.

This technique somehow forced the OS to flush the buffers to disk even on the stuck FP app, so nothing was lost, except maybe the unfinished document they were typing at the moment. But then, there was no way then, in FPD2.6, to salvage the app - it had to be killed.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform