Microsoft KB Archive/37530

From BetaArchive Wiki
< Microsoft KB Archive
Revision as of 19:21, 12 August 2020 by X010 (talk | contribs) (X010 moved page Microsoft KB Archive/Q37530 to Microsoft KB Archive/37530 without leaving a redirect: Text replacement - "Microsoft KB Archive/Q" to "Microsoft KB Archive/")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

COBOL 3.00 Can Create MS OS/2 Threads with Protected Mode API

PSS ID Number: Q37530 Article last modified on 04-26-1991

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

Summary: Microsoft COBOL Version 3.00 or 3.00a can create and use threads by calling API (Applications Program Interface) routines in MS OS/2 protected mode. The following example demonstrates how to create an MS OS/2 thread: 1. Compile the first thread as follows: PCOBOL THREAD1; 2. Link the first thread as follows: LINK THREAD1 /NOP,,,PCOBOL+DOSCALLS; 3. Compile the second thread as follows: PCOBOL THREAD2; 4. Create a .DEF file. 5. Create the Dynamic Link Library as follows: LINK THREAD2 /NOP,,,PCOBOL+DOSCALLS,THREAD2.DEF; 6. Move the new THREAD2.DLL to a directory specified by the LIBPATH= variable that resides in the CONFIG.SYS or CONFIG.OS2 file. 7. Run the threads by executing THREAD1.EXE.

More Information: A source code example of the above can be found in the Software/Data Library in the file COBTHRED by searching on the keyword COBTHRED, the Q number of this article, or S12102. COBTHRED was archived using the PKware file-compression utility.

Copyright Microsoft Corporation 1991.