- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi everyone,
I've received a program that seems to work correctly on windows 7 (code block+fortran)
I've ran it on windows xp (vitrual machine), i've got these errors.
1) forrt1: severe 29: file not found, unit 50
I've made some changes in the OPEN instruction, then I've got that new error message
2)forrt1: severe 24: end -of-file during read, unit 50
I've tried to use debugger and now the error message i get is " user break point from code at 0*7c90120e"
I've n idea how to fix it; can anyone help me.
I've installed a virtual windows xp machine on my windows 7. And i work with developer studio. My code was written in f90.
Thank u
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok - that means at line 418 of BUG.F90 you have a READ statement that tried to read past the end of the file DATA_HE.DAT. You'll have to figure out why that is - either the data file is missing some values or, earlier in the program, more data was read than was intended.
Another possibility, if this is the first READ in the program, is that the data file you wanted to read is actually somewhere else other than in "programme". It looks as if this is the project folder (the folder where the .vfproj file lives), and that's the default location when a file is opened. If there was no file there before, what will happen is that a new, empty file gets created and then the READ will fail.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
First, that is not a compilation error, it is a run-time error. When you get the "user breakpoint" message the real error is in the console window which may be obscured by the debugger window. Check the task bar to find the application's console window.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you Steve for your answer. You're right it's a run-time error. I've stopped debugger. I still not understand.
What should i do with the application's console window.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What message is in the console window? It could be something like an out-of-bounds array reference, or uninitialized variable reference, or an I/O error. Don't stop the program or else the window will go away. Just click on the task bar icon for the program's output window and look.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That's what i get as error
forrtl: severe (24): end-of-file during read, unit 50, file C:\Documents and Set
tings\XPMUser\My Documents\Simulations\BUG\programme\DATA_HE.DAT
Image PC Routine Line Source
programme.exe 0041A279 Unknown Unknown Unknown
programme.exe 0041A073 Unknown Unknown Unknown
programme.exe 00419204 Unknown Unknown Unknown
programme.exe 0041947E Unknown Unknown Unknown
programme.exe 004151BE Unknown Unknown Unknown
programme.exe 0040581E READINPUT 418 BUG.F90
programme.exe 0040126E BUG_HE 42 BUG.F90
programme.exe 004441F9 Unknown Unknown Unknown
programme.exe 00437624 Unknown Unknown Unknown
kernel32.dll 7C816037 Unknown Unknown Unknown
Press any key to continue
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok - that means at line 418 of BUG.F90 you have a READ statement that tried to read past the end of the file DATA_HE.DAT. You'll have to figure out why that is - either the data file is missing some values or, earlier in the program, more data was read than was intended.
Another possibility, if this is the first READ in the program, is that the data file you wanted to read is actually somewhere else other than in "programme". It looks as if this is the project folder (the folder where the .vfproj file lives), and that's the default location when a file is opened. If there was no file there before, what will happen is that a new, empty file gets created and then the READ will fail.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for the suggestions, i'll verify it and let you know.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
"I've made some changes in the OPEN instruction, then I've got that new error message". Well, changing an OPEN statement in an inappropriate way can certainly cause a previously working program to malfunction. You should provide us more details or, better, the source and data files so that we can see what causes the run time error.
To avoid the problem that Steve Lionel described (viz., opening a file for input when the file is not present in the current directory and causing a new zero-length file to be created) can be avoided by using the STATUS='OLD' clause in the OPEN statement. This clause will cause a run time abort to occur earlier (when the OPEN statement is run and fails) and enable to fix the problem at a more opportune time.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I already use the OLD option in the OPEN instruction. About providing the data file, i should discuss first with my boss.
I've got the code as it , it seems its worked . The first time i run it on my computer; i've got the error message.
I'm trying to see where the problem is.
Thank you so much for your help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It won't do any good to show us the data file if we can't also see the program. The basic problem is that the program is either reading the wrong file or is reading too much data.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve; the second possibility seems to bring out where the problem was .
i've moved all the files in 'programme'.
But now i get this message.
FINISHEDREADING DA
TA_HE.DAT
forrtl: severe (161): Program Exception - array bounds exceeded
Image PC Routine Line Source
programme.exe 00408FD5 READINPUT 603 BUG.F90
programme.exe 0040126E BUG_HE 42 BUG.F90
programme.exe 00444219 Unknown Unknown Unknown
programme.exe 00437644 Unknown Unknown Unknown
kernel32.dll 7C816037 Unknown Unknown Unknown
Press any key to continue
Thank you so much
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok, now you have a programming error you need to solve, where an array reference is out of bounds. You should run the program under the debugger and when it stops at the error, look at array references and the values of the array indexes. We're sort of blind here in giving you more specific advice.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
All my problem are solve, for the second one i use the solution propose here
https://software.intel.com/en-us/forums/topic/272902
Thank you so much for your help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Not checking bounds might solve the problem in some cases but also will hide real bugs in the code. It is a bit like taking the oil warning light out of the car rather than checking the oil level....
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page