Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!ucsd!mvb.saic.com!dayton.saic.com!fac2 From: fac2@dayton.saic.com (Earle Ake) Newsgroups: comp.lang.fortran Subject: Re: VAX/VMS Fortran: Record length in BYTES Message-ID: <1990Dec22.181822.1407@dayton.saic.com> Date: 22 Dec 90 22:18:21 GMT References: <5125.2767b5c5@cc.curtin.edu.au> <1990Dec17.173038.6222@eagle.lerc.nasa.gov> <1521@tharr.UUCP> Organization: Science Applications Intl. Corp., Dayton, Ohio Lines: 28 In article <1521@tharr.UUCP>, gombo@tharr.UUCP (Alun Jones) writes: [lines deleted] > What is causing problems, though, is the use of files with a fixed record > length. So far, I've just gone through and multiplied every RECL part of > an OPEN statement by 4, and the program appears to work now. Is there any > quick check I can apply to see which OPENs will require this treatment? From the book "Programming in VAX FORTRAN", chapter 13, the way VAX FORTRAN intreprets RECL on an open statement is such: "If the records are formatted, the length is the number of bytes." "If the records are unformatted, the length is the number of longwords." By default, files are opened as formatted unless otherwise specified. Multiply record lengths by 4 if there is a 'FORM=UNFORMATTED' parameter only. If the parameter looks like 'FORM=FORMATTED' or there is not a 'FORM=' parameter then the 'RECL' you have is in bytes. Hope this helps. Earle _____________________________________________________________________________ ____ ____ ___ Earle Ake /___ /___/ / / Science Applications International Corporation ____// / / /__ Dayton, Ohio ----------------------------------------------------------------------------- Internet: fac2@dayton.saic.com uucp: dayvb!fac2