Microsoft KB Archive/32161

Trap 13; Cannot CHAIN or CALL in MS OS/2 Protected Mode

PSS ID Number: Q32161 Article last modified on 04-21-1993

3.00 MS-DOS

Summary: The code produced by the Microsoft COBOL Compiler version 3.0 does not support a CALL or CHAIN to an EXE file statement when executed in MS OS/2 protected mode. If a CALL or CHAIN to an EXE file is executed in OS/2 mode, a Trap 13 (protection violation) will occur. This is incorrect behavior. Even though COBOL cannot CHAIN or CALL to EXE files in protected mode, the error that should occur is not a protection violation, but is instead an error stating that the specified EXE file cannot be found. This is because COBOL will be looking for a file with a DLL extension. This problem was corrected in Microsoft COBOL Professional Development System version 4.0 for MS-DOS and MS OS/2. CALLING and CHAINING can be accomplished in OS/2 if the CHAINed to or CALLed to program is a dynamic-link library. This knowledge base contains specific articles on CHAINing to a DLL and CALLing a DLL.

Additional reference words: 3.00 Copyright Microsoft Corporation 1993.