Created On:  10 January 2013


Customer was converting an application from Net Express to Visual COBOL.  The application was using Dialog System and the extension called DSONLINE which allows you to display Windows Help files in the .HLP format from within Dialog System screens.

Customer installed the Visual COBOL Compatibility Addpack to provide support for Dialog System in Visual COBOL but the DSONLINE support was not available.  How can an application using Dialog System and DSONLINE callouts be run in Visual COBOL?


The Dialog System extension DSONLINE was made available in a file named DSONLINE.GNT which exists in the Net Express\base\DialogSystem\bin folder.
This file has not been ported to Visual COBOL and it is documented as not being supported in Visual COBOL.

If you wish to run your Visual COBOL Dialog System applications that use DSONLINE then you must copy the DSONLINE.GNT file from Net Express to your applications output folder and this should work as it did in Net Express.

A demo program has been attached to this article which uses DSONLINE in Visual COBOL.

*                           HELPDEMO
* This example demonstrates how to use context sensitive help in
* a Dialog System application. This program was converted from
* Net Express where it resided in the folder HELPDEMO.
* This example uses the Dialog System extension DSONLINE which is
* available in Net Express but was not ported to Visual COBOL.
* In order to run the demo or to use Windows .HLP files in your
* application you need to make the file DSONLINE.GNT from the Net
* Express\DialogSystem\bin folder available to your Visual COBOL
* application. I have included it here as part of the demo pro-
* ject and have set it so it will be copied into the output fol-
* der so it can be found when called.
* To use Dialog System with Visual COBOL you also need to install
* the Visual COBOL Compatibility Addpack which is available for
* download on the Product Updates page of the Supportline web
* site. 
* If you are running under Windows Vista or higher you will also
* need to install the WinHlP32 files from Microsoft as support
* for this older .HLP format is not native to anything above
* Windows XP.

 78 dialog-system VALUE "DSGRUN".
 01 Display-Error.
    03 Display-Error-No PIC 9(4) comp-5.
    03 Display-Details-1 PIC 9(4) comp-5.
    03 Display-Details-2 PIC 9(4) comp-5.
 COPY "helpdemo.CPB".
 Main-Process SECTION.
    PERFORM Program-Initialize
    PERFORM Program-Body
    PERFORM Program-Terminate
 Program-Initialize SECTION.
    INITIALIZE Ds-Control-Block
    INITIALIZE Data-block
    MOVE Data-block-version-no
       TO Ds-Data-Block-Version-No
    MOVE Version-no TO Ds-Version-No
    MOVE Ds-New-Set TO Ds-Control
    MOVE "helpdemo" TO Ds-Set-Name
 Program-Body SECTION.
    PERFORM Call-Dialog-System
 Program-Terminate SECTION.
 Call-Dialog-System SECTION.
    CALL dialog-system USING Ds-Control-Block,
    IF NOT Ds-No-Error
       MOVE Ds-System-Error TO Display-error
       DISPLAY "DS ERROR NO: " Display-error-no
       DISPLAY "Error Details(1) : " Display-Details-1
       DISPLAY "Error Details(2) : " Display-Details-2
       PERFORM Program-Terminate

Incident #2607243