Path: utzoo!mnetor!uunet!lll-winken!lll-tis!ames!pioneer!pstevens From: pstevens@pioneer.arpa (Paul Stevens RCE Sterling) Newsgroups: comp.os.vms Subject: Re: Records in fortran Message-ID: <7384@ames.arpa> Date: 14 Apr 88 14:23:02 GMT References: <91*dahls@vax.elab.unit.uninett> Sender: usenet@ames.arpa Reply-To: pstevens@pioneer.UUCP (Paul Stevens RCE Sterling) Organization: NASA Ames Research Center, Moffett Field, Calif. Lines: 23 In article <91*dahls@vax.elab.unit.uninett> dahls%vax.elab.unit.uninett@TOR.NTA.NO (J|rn Yngve Dahl-Stamnes) writes: > >Is there somebody out there who know how to use DATA statement on RECORD >fields in FORTRAN? I can't find any info about this in the yellow binders. > The answer is that you can only use an data statement on the STRUCTURE declaration and not on the RECORD statement. STRUCTURE /MY_STRUC/ INTEGER*4 A_FIELD /99/ INTEGER*2 ANOTHER /0/ END STRUCTURE RECORD /MY_STRUC/ MY_REC(3) Of course this will put it into all of the fields of MY_REC. However, since record fields may not be atomic, what other choice is there? ----------------------------------------------------------------------- Paul Stevens - NASA Ames Research Center Moffet Field CA Mail Stop 233-10 (415)694-4887 pstevens@ames-pioneer.arpa