Microsoft KB Archive/49492

Must Use FD Name As Parameter to CALL X“91” Functions 46-49

PSS ID Number: Q49492 Article last modified on 04-20-1993

3.00 3.00a | 3.00 3.00a MS-DOS | OS/2

Summary: In Microsoft COBOL Versions 3.0 and 3.0a for MS-DOS and OS/2, the extension routine CALL X“91” functions 46 through 49 allow you to change the behavior of COBOL when operating on a particular LINE SEQUENTIAL file, as follows: Function 46 - Enables insertion of null characters Function 47 - Disables insertion of null characters Function 48 - Enables insertion of tab characters Function 49 - Disables insertion of tab characters When using any of these four functions, the last parameter needs to be the literal FD name, without surrounding quotation marks, of the file you want to use. The CALL X“91” routine is documented on Pages 8-9 through 8-14 of the “Microsoft COBOL Compiler 3.0: Operating Guide” for Microsoft COBOL 3.0 and 3.0a for MS-DOS and OS/2.

More Information: The following is an example of a program that demonstrates the use of CALL X“91”, function 47, to disable the insertion of null characters to a LINE SEQUENTIAL file. Note the parameter to CALL X“91” is the literal FD name of the file. ENVIRONMENT DIVISION. INPUT-OUTPUT SECTION. SELECT testfile ASSIGN TO DISK ORGANIZATION IS LINE SEQUENTIAL. DATA DIVISION. FILE SECTION. FD testfile VALUE OF FILE-ID IS “testfile.dat”. 01 testrec PIC X(80). WORKING-STORAGE SECTION. 01 result PIC 99 COMP-X. 01 fun PIC 99 COMP-X. PROCEDURE DIVISION. OPEN OUTPUT testfile. MOVE 0 to result. MOVE 47 to fun. CALL X“91” USING result, fun, testfile. DISPLAY result. CLOSE testfile. STOP RUN.

Additional reference words: 3.00 3.00a Copyright Microsoft Corporation 1993.