- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello, everyone. My name is Harry Kim, and I am working on modifying a pre-made Fortran Program. I got stuck on 'unit number' in an open statement for 3 days.
in my source file... I found a open statement like below.
---------------------------
c define unit number
item = 14
c open file containing temperature data
open(item,file=prefix(:l_prfx)//'.tem',status='old')
---------------------------
I am trying to make a new data file (*.chm) and read data the same way as above.I made new variables (ichm) for new unit number, andwrotethe same. However, my programcannot read my new data file.
WhatI want todo nowis tocheck the unit number of my new variable (ichm) and designate it before the open statement.
I foundsome other unit numbers...
item = 14
ibcvs = 15
isoi = 16
However,I cannot find unit 1~13. So... I just tried 'ichm = 17'and'ichm = 18', but there was no difference.
Please let me know if anyonehas any suggestions for this problem. Thanks.
Message Edited by Harry27606 on 07-07-2004 01:14 AM
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Unit number will not make any difference, as long as it is unique.
The error most likely lies in discrepancy of the format of the actual file and the way you're reading it. What is the error message?
Jugoslav
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
As you mentioned, there was no error. The problem is that my program doesn't read my data file. Mmm... Then, there is no problem on my unit number.
O.K.! I will check my source file again. Thank you, Jugoslav.

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page