Highlighted
Absent Member.
Absent Member.
1554 views

RM POP UP Problem

Jump to solution

Deasr Larry,

Enclosed the Result of Command Execution.....

Pedro Juan Montero Bernales

PJM Informatica Soluciones Globales

Santiago - Chile

0 Likes
1 Solution

Accepted Solutions
Highlighted
Absent Member.
Absent Member.

RE: RM POP UP Problem

Jump to solution

After discovering that development was on Eclipse for Windows, this was answered in another copy of this thread topic as requiring the cbllink command to link in COBWIN2.obj.  Further investigation shows there are other alternatives.

(1) When producing an EXE with Eclipse, a reference to COBWIN2.dll is automatically inserted in the EXE and the entry point CBL_OPEN_WINDOW will be found with the EXE is executed (presuming COBWIN2.dll can be found in the execution environment).  As noted elsewhere, an EXE built on Windows is not portable to UNIX.  If dynamic linking with a DLL is not desired, COBWIN2.obj can be linked into the executable by specifying it in the project properties Micro Focus / Build Configurations / COBOL / Link / Additional Link Files with the Add External Files ... button and navigating to the COBWIN2.obj in the Micro Focus installation.

(3) If portability to UNIX is desired, the Eclipse project can be set (in project properties Micro Focus / Build Configurations / COBOL / Target Settings / Target Type, choosing All Int/Gnt Files in the drop down list.  The Int files can be moved to UNIX.  However, note that 32 bit and 64 bit Int files cannot be intermixed.  With Int files, the initcall(cobwin2) directive needs to be specified when using popup windows; this can be done in the project properties Micro Focus / Project Settings / COBOL / Additional directives: text box).  Also, the ADISCTRL file has a different format on Windows and UNIX.  For programs that were originally RM/COBOL, the RM2VCOB configuration needs to be selected in the ADISCTRL file (on Windows or UNIX).  Similarly, for programs that were originally ACUCOBOL, the ACU2VCOB configuration  needs to be selected.  On UNIX, the adisctrl file is often in /etc and not writable; to change the default configuration (using the adiscf utility), it is generally best to copy the adisctrl file to your working directory as a writable copy and then choosing the RM2VCOB or ACU2VCOB configuration as the default, which requires rewriting the file.

View solution in original post

0 Likes
3 Replies
Highlighted
Absent Member.
Absent Member.

RE: RM POP UP Problem

Jump to solution

I think the problem is that Larry left out the source name in the command.

       cob popup-app.cbl -xI COBWIN2 -o popup-app

where popup-app.cbl is the name of your application COBOL source file and popup-app is the name of the desired executable file that will include the required COBWIN2.

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: RM POP UP Problem

Jump to solution

Note that if you already have the object file (for example, popup-app.o), you can just link in COBWIN2 with the following command:

        cob popup-app.o -xI COBWIN2 -o popup-app

If there are multiple object files, just list them in place of popup-app.o in the above example.

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: RM POP UP Problem

Jump to solution

After discovering that development was on Eclipse for Windows, this was answered in another copy of this thread topic as requiring the cbllink command to link in COBWIN2.obj.  Further investigation shows there are other alternatives.

(1) When producing an EXE with Eclipse, a reference to COBWIN2.dll is automatically inserted in the EXE and the entry point CBL_OPEN_WINDOW will be found with the EXE is executed (presuming COBWIN2.dll can be found in the execution environment).  As noted elsewhere, an EXE built on Windows is not portable to UNIX.  If dynamic linking with a DLL is not desired, COBWIN2.obj can be linked into the executable by specifying it in the project properties Micro Focus / Build Configurations / COBOL / Link / Additional Link Files with the Add External Files ... button and navigating to the COBWIN2.obj in the Micro Focus installation.

(3) If portability to UNIX is desired, the Eclipse project can be set (in project properties Micro Focus / Build Configurations / COBOL / Target Settings / Target Type, choosing All Int/Gnt Files in the drop down list.  The Int files can be moved to UNIX.  However, note that 32 bit and 64 bit Int files cannot be intermixed.  With Int files, the initcall(cobwin2) directive needs to be specified when using popup windows; this can be done in the project properties Micro Focus / Project Settings / COBOL / Additional directives: text box).  Also, the ADISCTRL file has a different format on Windows and UNIX.  For programs that were originally RM/COBOL, the RM2VCOB configuration needs to be selected in the ADISCTRL file (on Windows or UNIX).  Similarly, for programs that were originally ACUCOBOL, the ACU2VCOB configuration  needs to be selected.  On UNIX, the adisctrl file is often in /etc and not writable; to change the default configuration (using the adiscf utility), it is generally best to copy the adisctrl file to your working directory as a writable copy and then choosing the RM2VCOB or ACU2VCOB configuration as the default, which requires rewriting the file.

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.