Printing From FORTRAN with Control Characters

ID: Q35867


The information in this article applies to:
  • Microsoft FORTRAN for MS-DOS, versions 4.0, 4.01, 4.1, 5.0, 5.1
  • Microsoft FORTRAN for OS/2, versions 4.1, 5.0, 5.1
  • Microsoft FORTRAN PowerStation for MS-DOS, versions 1.0, 1.0a
  • Microsoft Fortran Powerstation 32 for Windows NT, versions 1.0, 4.0


SUMMARY

In Microsoft FORTRAN, an application can send control characters directly to a printer with out printing them by using the CHAR intrinsic function.


MORE INFORMATION

The following code example prints the word "Hello," sends a form feed character (ASCII 12) to the printer, then prints the word "World."

Sample Code


C Compiler options required: None

      OPEN(6, FILE = 'LPT1', STATUS = 'OLD')
      WRITE(6, *) 'HELLO'
      WRITE(6, *) CHAR(12)
      WRITE(6, *) 'WORLD'
      END 

Additional query words: kbinf 1.00 4.00 4.01 4.10 5.00 5.10

Keywords : kbcode kbFortranPS kbLangFortran
Version : :1.0,1.0a,4.0,4.01,4.1,5.0,5.1
Platform : MS-DOS OS/2 WINDOWS
Issue type :


Last Reviewed: November 2, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.