FIX: CHAR(26) to Device Causes F6422: No Space Left on Device

Last reviewed: September 11, 1997
Article ID: Q71464
3.13 3.20 3.31 3.33 4.00 4.01 4.10 5.00 5.10 MS-DOS kbtool kbfixlist kbbuglist

The information in this article applies to:

  • Microsoft FORTRAN for MS-DOS, versions 3.13, 3.2, 3.31, 3.33, 4.0, 4.01, 4.1, 5.0, and 5.1

SYMPTOMS

A program compiled with Microsoft FORTRAN that attempts to write CHAR(26) to a device such as the printer or screen, may have as a result one of the following problems during execution under MS-DOS:

  1. Run-time error F6422: WRITE(device) - no space left on device

  2. No character is output.

  3. ? error: Device full error in file(device) Error Code 1028; Status 0008; PC=11AA; 000C; SS=29BE; FP=0008; SP=1196

Compiling the same program with FORTRAN version 4.1, 5.0 or 5.1 for protected-mode execution and running under OS/2 will print the desired ASCII character (left arrow) to the device.

STATUS

Microsoft has confirmed this to be a problem in Microsoft FORTRAN versions 3.x, 4.x, and 5.x for MS-DOS. This problem was corrected in FORTRAN PowerStation.

MORE INFORMATION

The following program illustrates the problem of sending CHAR(26) to a device. The user inputs the device that CHAR(26) is to be sent to into the variable "flnm." Possible devices include the screen (CON), printer (PRN, LPT1), or communications port (COM1).

      character*5 flnm
      read(*,'(a)') flnm
      open(1,file=flnm,status='old')
      write(1,'(1x,a)') char(26)
      end

CHAR(26) is the ASCII code for the end-of-file marker or CTRL+Z (^Z). When this character is output to a device under MS-DOS, as in the program above, the character may be suppressed or the F6422 run-time error may be generated.

CHAR(26) can be sent to a file correctly, which can then be sent to the desired device. It can also be sent to a device correctly while running under OS/2.


Additional reference words: 5.00 5.10
KBCategory: kbtool kbfixlist kbbuglist
KBSubcategory: FLIss
Solution Type : kbfix


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: September 11, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.