Home > Archive > Cobol > October 2006 > Interfacing with C
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Interfacing with C
|
|
| guigouz 2006-10-18, 9:55 pm |
| Hello
When a Cobol program CALLs another program, what is passed to the
new program, and how it is passed ?
I'm asking it because I want to create a C program that receives
some information from cobol. Is it possible ?
Just a side note, we use novell 3.12 and the cobol compiler from
that era.
Thanks in advance for any information
Guilherme Barile
| |
| Richard 2006-10-18, 9:55 pm |
|
guigouz wrote:
> When a Cobol program CALLs another program, what is passed to the
> new program, and how it is passed ?
That depends on what is specified in the source, the compiler and
options given to the compiler.
In the simplest case the USING paramers are passed as addresses of the
data areas (ie thiese may be pointers).
> I'm asking it because I want to create a C program that receives
> some information from cobol. Is it possible ?
Whether it is possible depends on whether the Cobol compiler generates
code that is compatible with the code that the C compiler generates.
> Just a side note, we use novell 3.12 and the cobol compiler from
> that era.
'That era' may be the 80s. Is the compiler running on the Novell
machine or is the Novell just a red herring because it is just a file
server ?
What brand and version of Cobol and of C are you using and what OS will
they target. Where will the executable run ?
There are thousands of combinations that would never work, there may be
a few that do.
| |
| Vivian 2006-10-30, 6:55 pm |
| We call C, C++, assembler, and even Java from within our Cobol
programs. We use an old compiler too, but for MVS, so can't help you
with Novell. But, the concept is definitely doable.
guigouz wrote:
> Hello
> When a Cobol program CALLs another program, what is passed to the
> new program, and how it is passed ?
> I'm asking it because I want to create a C program that receives
> some information from cobol. Is it possible ?
>
> Just a side note, we use novell 3.12 and the cobol compiler from
> that era.
>
> Thanks in advance for any information
>
> Guilherme Barile
|
|
|
|
|