Solved

Visual FoxPro 9.0 SP2  Error writing to file "file" (Error 1105)

Posted on 2015-01-05
3
616 Views
Last Modified: 2015-01-08
I have a Windows Xp Pro Machine that is running MS Visual FoxPro 9.0 applications
These applications ran from a scheduled task that is handled by the task manager.
These apps access data bases on a network share but from time to time Fox Scheduler tries to write to one of the files and it errors out with this message

Visual FoxPro 9.0 SP2
Error writing to file "file" (Error 1105)
The operating system returned an error while Visual FoxPro was attempting to write to the specified file. Most often, this error occurs when attempting to write to a write-protected disk.
But this machine has access to the file and it work majority of the time just once in a while it will error out.
0
Comment
Question by:ahmad1467
3 Comments
 
LVL 11

Expert Comment

by:Ganesh Kumar A
ID: 40532877
The operating system returned an error while Visual FoxPro was attempting to write to the specified file. Most often, this error occurs when attempting to write to a write-protected disk or the file might be used or diskspace issue or clean the temp files and try (C:\windows\temp and profile temp folder).

Errorcodes : http://msdn.microsoft.com/en-us/library/aa979346(v=vs.71).aspx

It appears like network share doesn't have read & write permission. Check the permission the issue will be resolved.
0
 
LVL 29

Expert Comment

by:Olaf Doschke
ID: 40533100
As this is only temporary a reason may be your task is locking itself out.
To which files do you write? DBFs via SQL or REPLACE? or txt files via FOPEN/FWRITE?

Any way, a file always can only be written to by one process at each time, that's deep in the OS and not only valid for DBFs, but any type of files. You can read shared, but never write shared, so the best thing to do is put write operations into try/catch and repeat unsuccessful writes after a random timeout (otherwise two processes using the same timeout might deadlock themselves in sync).

You may well have a branch of your code not closing a file and causing a long term lock, this or similar reasons should of course be found and eliminated.

Bye, Olaf.
0
 
LVL 42

Accepted Solution

by:
pcelba earned 500 total points
ID: 40533261
Error 1105 is low level OS error and appears namely on unstable network connections. The problem is in your network hardware (90%) or in some software which can prohibit the file access (e.g. some incompatible antivirus or backup software).

Any connection dropout during the write operation can cause this error. You may simulate it by disconnecting network cable during the write operation...

Neither permissions nor simultaneous data access can cause this error. These events are solved at higher level.

When the error 1105 appears your data may become inconsistent or even corrupted. Reindex and data integrity check is highly recommended after this error occurrence.
0

Featured Post

How Do You Stack Up Against Your Peers?

With today’s modern enterprise so dependent on digital infrastructures, the impact of major incidents has increased dramatically. Grab the report now to gain insight into how your organization ranks against your peers and learn best-in-class strategies to resolve incidents.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Foxpro9 import of excel Table 4 603
vfp 9 and macintosh 7 160
Newly reinstalled FoxPro 9 has serious problems Please advise 6 97
How to update a record in foxpro 3 8
Microsoft Visual FoxPro (short VFP) is a programming language with it’s own IDE and database, ranking somewhat between Access and VB.NET + SQL Server (Express). Product Description: http://msdn.microsoft.com/en-us/vfoxpro/default.aspx (http://msd…
Did you know that more than 4 billion data records have been recorded as lost or stolen since 2013? It was a staggering number brought to our attention during last week’s ManageEngine webinar, where attendees received a comprehensive look at the ma…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question