XANSYS Message: 42819 [Go back to message list]
[bookmark on del.icio.us]
No rating yet
Rate item:

Subject: Leading Zeros in *VWRITE Fortran Formatting?
Author: John Crawford
Date: 2002-10-17 11:47:00

Here's another *VWRITE question that I hope someone has an answer for. I
want to write out the date and time using *VWRITE. I am using Fortran
formatting because it lets me control character spacing. The problem is
that for minutes less than 10 I want to print out a leading zero to avoid
printing "Time: 8: 3" when I really want it to print out "Time: 8:03". Is
there a Fortran format command in *VWRITE that will do this?

Here's what I have in my macro.

*vwrite,month,day,year,hour,minute
(14x,'Date: ',f3.0,tl1,'-',f3.0,tl1,'-',f5.0,tl1,' ',38x,'Time:
',f3.0,tl1,':',f3.0,tl1,' ')

Thanks for any suggestions.

John Crawford
Honeywell Engines and Systems
Tempe, AZ

Posts possibly associated with message #42819AuthorDateScore
42819Leading Zeros in *VWRITE Fortran Formatting?John Crawford2002/10/17 
42820Re: Leading Zeros in *VWRITE Fortran Formatting?Dean Brown2002/10/17 
42821Re: Leading Zeros in *VWRITE Fortran Formatting?Gordon May2002/10/17 
42822Re: Leading Zeros in *VWRITE Fortran Formatting?Chris Bridge2002/10/17 
42826Re: Leading Zeros in *VWRITE Fortran Formatting?John Crawford2002/10/17