Incomprehensible list input

  • Thread starter snowdrop
  • Start date
1
0

Main Question or Discussion Point

Hi all,

I am trying to run a fortran 77 program which was compiled using g77 and it comes up with the following error ::

invalid number: incomprehensible list input
apparent state: internal I/O
lately reading sequential formatted internal IO
Abandon

:confused:

I want the program to read some data files and analyse them so I have written the list like this ::

file01.dat
file02.dat
file03.dat
file04.dat
I have no idea why this error is coming up... I have checked the program and he seems fine and I have declared the list in the declarations. The part of code used to open the file with the list of data files is the following ::

open (20,file=liste(1:lliste),form='formatted',status='old')
If any one has any ideas what the problem could be.. :frown:

Thanks in advance :bugeye:
 

Answers and Replies

AlephZero
Science Advisor
Homework Helper
6,953
291
The error message is about a read statement, not an open statement. If says the data in the file was in the wrong format.

If you want to do read character strings with list-directed I/O like

character*50 liste
read(*,*) (liste)

then the character strings in the data file must be in quotes

'file1.dat'
'file2.dat'
...

To read character data without the quotes, do a formatted read using A format:

read(*,'A') (liste)
 

Related Threads for: Incomprehensible list input

Replies
1
Views
4K
  • Last Post
Replies
15
Views
382
  • Last Post
Replies
9
Views
4K
  • Last Post
Replies
12
Views
2K
  • Last Post
Replies
1
Views
3K
Replies
8
Views
494
  • Last Post
Replies
18
Views
1K
Top