Skip to main content

initialization of linkage in managed code

  • April 19, 2022
  • 7 replies
  • 0 views

Someone is using initialize (which works fine in unmanaged code) to initialize linkage.

He says the pic x's are correctly set to spaces, but numerics are not set to zero.  Is there more involved?

Thanks.


#managed

7 replies

Chris Glazier
Forum|alt.badge.img+2

Someone is using initialize (which works fine in unmanaged code) to initialize linkage.

He says the pic x's are correctly set to spaces, but numerics are not set to zero.  Is there more involved?

Thanks.


#managed

I cannot reproduce this behavior. It works fine for me.

Can you please provide a small example of what you are doing?

Thanks.


  • April 20, 2022

I cannot reproduce this behavior. It works fine for me.

Can you please provide a small example of what you are doing?

Thanks.

He says heI can't initialize the linkage record (using a simple initialize statement) in a new program using the ILSMARTLINK directive.  I don't have an example unfortunately.


Chris Glazier
Forum|alt.badge.img+2

He says heI can't initialize the linkage record (using a simple initialize statement) in a new program using the ILSMARTLINK directive.  I don't have an example unfortunately.

I cannot reproduce this using VC 7.0 PU7.

What product version are you using?

Is it a COBOL main program that is calling the subprogram or is it C# or something else?


  • April 20, 2022

I cannot reproduce this using VC 7.0 PU7.

What product version are you using?

Is it a COBOL main program that is calling the subprogram or is it C# or something else?

The problem occurred when initializing the linkage record of a called COBOL program from another COBOL program.


Chris Glazier
Forum|alt.badge.img+2

The problem occurred when initializing the linkage record of a called COBOL program from another COBOL program.

Does it work if the ilsmartlinkage directive is not set?

I cannot replicate that behavior. I will need an example from you that fails.


  • April 21, 2022

Does it work if the ilsmartlinkage directive is not set?

I cannot replicate that behavior. I will need an example from you that fails.

Hi, we are on Micro Focus Visual COBOL 5.0 Version 5.0.00077.- wionder if that has to do with it...


Chris Glazier
Forum|alt.badge.img+2

Hi, we are on Micro Focus Visual COBOL 5.0 Version 5.0.00077.- wionder if that has to do with it...

I just tested this on V5.0 as well and I cannot reproduce the problem with my test program. I would recommend that you open up a support incident and attach a cutdown project that replicates the behavior.