Character Mode Dialog System

The character based Dialog System is available with the latest Visual COBOL PE. Looking at the  Dialog System Character Mode Guide the Tutorial Section makes reference to many example programs (*.s, *.err, *.sl, *.cbl, *.mf, *.cpb etc.)

Is there a website where I might download these programs as they are not included in the Visual COBOL release?

Thanks

  • Can you please provide a link to the Dialog System Character Mode Guide that you are referencing? This does not appear to be part of the Visual COBOL product. Perhaps you are looking at Net Express or Server Express documentation?

    The character based Dialog System support is included in Visual COBOL for compatibility for systems that were written using this technology in earlier products to allow them to be moved forward. It should not really be used for any new development.

    What is it that you are trying to achieve? Perhaps we can make other recommendations for you.
    Thanks
  • Chris

    You are correct, I'm looking at the Net Express documentation supportline.microfocus.com/.../dcpubb.htm

    I have an interest in these legacy dialog systems and am wanting to do some personal development. I am aware of the more 'modern' approaches, in COBOL and C#, but I merely want to try out the Dialog System and have never had access to it before now. So, simply interest.

    Thanks
  • Looking at that link, at least the first "Sample Session in Character Mode" does not require any additional files - it gives instructions for creating all the files you need for the basic demo. (Oddly the UNIX version says to copy test1.cbl from the samples directory, but then tells you to create the file using an editor and shows what the file should contain).

    I notice the way to run Dialog System in character mode has changed a little since that document:
    In Visual COBOL for UNIX, run "ds" from the command line rather than using tbox.
    In Visual COBOL for Windows, run "dscharenv" to set up the necessary environment and then "dschar".

    Hopefully that will be enough to get the demo working.
  • JonS

    Thanks. I'll try working through the examples and see how far I get. I don't have the UNIX version of DS - I'm certainly missing a samples directory.
  • JonS

    I have worked through the demo and created test1.cbl. As I don't have Net Express I used the 32-bit Professional COBOL compiler. The program checks and compiles correctly. But when I try to run the program I get "Load error: 'file DSRUN'".

    Is there a solution to this problem?
    Thanks
  • That is an error I would expect to see if the environment was not set up correctly - did you run "dscharenv" before trying to run your compiled program?
  • JonS

    I opened a windows command window and ran 'dschrenv' to set up a DOS-like environment. This allowed me to run the DS and create the various copy files. What I'm not sure of is how to compile the program in Visual COBOL. Even if I create a Console application and use VC to run it how do I get to run 'dscharenv'?

    What I did was copy the various DS .dlls into the exedll folder under Professional COBOL, checked, compiled and ran the resulting program. Now the program runs but does not display the screenset. I don't get the "Load error: 'file DSRUN'" this time. The program just doesn't display the required input screen.

    Thanks
  • JonS

    Ok I've been able to set up the DS environment using the Visual COBOL Command Prompt. From c:\users\paul\documents I enter:

    cd "c:\program files (x86)\micro focus\visual cobol\"

    CreateEnv.bat

    cd "c:\program files (x86)\micro focus\visual cobol\bin\"

    DSCharenv.bat

    cd "c:\program files (x86)\microsoft visual studio\2017\community\common7\ide"

    devenv c:\workarea\dsvcproj\dsproject\dsproject.sln

    This launches Visual COBOL with my project. When I run the project I stiil have the same problem - the screen set does not show.
  • Can anyone explain why I'm having this problem?
  • I think the issue is that the default environment (which is set up to enable the GUI version of Dialog System) is also applied when you run from the IDE, even if you ran the IDE from a character mode environment.

    It should be possible to update the environment explicitly in the project settings - I'll have a try and get back to you.