![]() ![]() Why constrain yourself with such design, with the inherent limitations of file I/O operations, in this day and age? I'm sure you realize the code design you provided in the original post dates back to the time when memory was so precious and limited. Given all the facilities in the modern Fortran language to create highly flexible and extensible data structures (derived types) with allocatable components, would you consider rearchitecting your code not to use files to write and read data inside of a loop? Instead, you can consider working with all the data in "memory" e.g., with the use of derived types and type-bound procedures? If required, you can then write it out the required data to a file at the end of all processing. We have more than 30 years of history with routines like this, from Microsoft 5.0 through all of its descendants, on a wide array of compilers and computers (but always DOS or Windows), and NEVER had any trouble like this, and now it is routine just because we are using a faster computer? There is something wrong with this picture. ![]() The program is type console, and it runs fine on an XP machine in command mode.Īny ideas what could be causing this behavior? There may be about 5 other files open at the same time, but they don't seem to affect the occurrence of this error. This error seems to occur randomly at any trip through the loop. More often, it produces the runtime error 'forrtl: severe (9): permission to access file denied, unit 60, file = path\dynbmrts.ts'. The above is in a loop that executes 36 times. OPEN (60, FILE = 'dynbmrts.ts', FORM = 'unformatted', ACCESS = 'direct', RECL =. My application deals with an unformatted direct access file. 0.5 sec per loop iteration-so even a small delay would cause it to run slower than what my users are willing to wait on! I will try putting in a trap for those (hopefully) rare occasions when the file access fails, and take appropriate action like simply retrying. I will continue to explore what happens by inserting a small delay in the loop, but I hate to think this is the solution because the program runs very fast right now-approx. This makes me wonder-could it be that IVF is not yet fully "qualified" on Windows 8.1? Is there any reason to suspect this might be the case? Anybody have any similar experiences? (They have different versions of IVF but I don't have the details handy right now.) And, it doesn't seem to matter what computer the exe was built on. The program runs reliably on a couple of computers under Windows 7, but it fails randomly on the computer running Windows 8.1. Yes, the program does need to close and reopen the file on every trip through the loop, because the record length (of this direct access file) needs to respond to certain parameters that may be different.Īs some more testing, I have tried running the same exe file on some other computers. ![]()
0 Comments
Leave a Reply. |