Highlighted
Absent Member.
Absent Member.
1265 views

C$JAVA issue CJAVA-CLASSNOTFOUND

I am facing an issue while using the sample Acucobol program to call Java from cobol. I have small piece of code in my cobol program as :

CALL "C$JAVA" USING CJAVA-CALLSTATIC "C:\Javaprojects\TestCobol2Java\bin\CobolCallingJava", "CobolCallingJavaInt", "(I)I", FIELD-INT, FIELD-RET GIVING STATUS-VAL

it returns status-val as "-3" which seems classnot found. Not sure if I mentioned the full path of the class file why it still could not found?

Any help?

0 Likes
1 Reply
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: C$JAVA issue CJAVA-CLASSNOTFOUND

Why have you place PATHING CALL "C$JAVA" USING CJAVA-CALLSTATIC "C:\Javaprojects\TestCobol2Java\bin\CobolCallingJava"

whereas our example is

CALL "C$JAVA" USING CJAVA-CALLSTATIC, "CobolCallingJava", "CobolCallingJavaInt", "(I)I", FIELD-INT, FIELD-RET   GIVING STATUS-VAL

Typically pathing as far as objects and resources are taken care of via configuration variables.

Have you tried setting up and executing our Java examples C:\Program Files (x86)\Micro Focus\Acucbl925\AcuGT\sample\java

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.