Highlighted
Absent Member.
Absent Member.
1344 views

testing the ICallBack program on Visual Cobol 2010 eclipse version

Jump to solution

[Migrated content. Thread originally posted on 13 June 2011]

I have tested the ICallBack program from the seminar on Visual Cobol 2010 eclipse as a jvm project
here is the code:

INTERFACE-ID ICallBack.
METHOD-ID SendMessage.
procedure division using by value msg as string.
end method.
END INTERFACE.

CLASS-ID BizLogic.
METHOD-ID CountMoney.
local-storage section.
01 i BINARY-LONG.
01 formatter pic $$$$9.

procedure division using by value max as BINARY-LONG
callBack as type ICallBack.

perform varying i from 1 by 1 until i > max
move i to formatter
invoke callBack::SendMessage(formatter)
end-perform.
end method.
end Class.

CLASS-ID Callback implements type ICallBack
METHOD-ID SendMessage
PROCEDURE DIVISION using by value msg as string.
display "Cobol Says" msg .
end method.
end class.


program-id. Program1 as "Program1".


data division.
01 callback type Callback.
01 counter type BizLogic.


procedure division.

set callback to new type Callback.
set counter to new type BizLogic.

invoke counter::CountMoney(10, callback ).


end program Program1.

This code gave me 3 errors in de code window but not error window
here are the errors showing at:
CLASS-ID BizLogic.
METHOD-ID CountMoney.

COBCH09125S Internal error Dictionary invalid r/w 00000000 Inform Technical Support
COBCH0223S Unknown USAGE
COBCH0012S Operand ICallBack is not declared

It will run as a cbl program in the Eclipse evironment but when I start the java class Program1.class in the dos window with "java Program1" it gives a trace with errors because of a ClassNotFoundException caused by the com.microfocus.cobol.program.IObjectControl. Can anyone explaine why this is. The class file Program1.class is present.

I also noticed that the intellisense in Visual Studio is much better then in Eclipse.
The code in Visual Studio is better completed than in Eclipse, because there, only words are completed
expl method-id is not followed with end method.
the methods of the interface are not implemented.
When you are making Java progams this is the standard. That is a pity.

I use another version of Eclipse that is better for making J2EE project. Maybe you should provide a plugin for this Eclipse just like Adobe did for there Flex framework for making flex projects.
0 Likes
1 Solution

Accepted Solutions
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: testing the ICallBack program on Visual Cobol 2010 eclipse version

Jump to solution
The version of the Visual COBOL Eclipse JVM product that you are using is R3 which is an "early technology release" of the JVM add-on product. It is not at the same release level as the Visual COBOL Visual Studio R3 release. There are many features that are not supported at that product level.

The version that Stephen is using is the upcoming R4 release of Visual COBOL Eclipse JVM which is the GA version. If you need to demonstrate that particular functionality then you should wait until the GA becomes available.

View solution in original post

0 Likes
3 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: testing the ICallBack program on Visual Cobol 2010 eclipse version

Jump to solution
I expect I am using a later version of Visual COBOL as it appears to work for me:


D:\DemosAndTests\callback
>cobol cb.cbl jvmgen sourceformat"free";
Micro Focus COBOL
Version 1.3.00046 Copyright (C) Micro Focus IP Development Limited 1984-2011.
* Checking complete with no errors

D:\DemosAndTests\callback
>java Program1
Cobol Says   $1
Cobol Says   $2
Cobol Says   $3
Cobol Says   $4
Cobol Says   $5
Cobol Says   $6
Cobol Says   $7
Cobol Says   $8
Cobol Says   $9
Cobol Says  $10

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: testing the ICallBack program on Visual Cobol 2010 eclipse version

Jump to solution
You are right.

This is what I get if I do : cobol Program1.cbl sourceformat"free";

Micro Focus COBOL
Version 1.2.00054 Copyright (C) 1984-2010 Micro Focus (IP) Limited.
*ss
* 317-S **
** Incorrect program structure
* 317-S **
** Incorrect program structure
* 143-S **
** Unknown IDENTIFICATION DIVISION paragraph
callBack as type ICallBack.
* 223-S************************ **
** Unknown USAGE
* 12-S********************************** **
** Operand ICALLBACK is not declared
invoke callBack::SendMessage(formatter)
* 912-S************************** **
** Internal error - Dictionary invalid r/w 00000000 Inform Technical Support.
* Checking terminated

It is one I downloaded for testing purposes and that I got from Mr Arunn Ramadoss.
We are using Net express but we are migrating from Apache server to a Windows 2008 server and my collegues told me that Net express is only running on a Apache server. I have to make a presentation for the purchase manager and I want to fully demonstrate the possibilities of your product , what do you advice me?
0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: testing the ICallBack program on Visual Cobol 2010 eclipse version

Jump to solution
The version of the Visual COBOL Eclipse JVM product that you are using is R3 which is an "early technology release" of the JVM add-on product. It is not at the same release level as the Visual COBOL Visual Studio R3 release. There are many features that are not supported at that product level.

The version that Stephen is using is the upcoming R4 release of Visual COBOL Eclipse JVM which is the GA version. If you need to demonstrate that particular functionality then you should wait until the GA becomes available.

View solution in original post

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.