Set Up the ProgramEJB Project

Walks you through the process of creating a Visual COBOL project for the BookDemo application.

Create the ProgramEJB project

  1. From the Eclipse main menu, click File > New > COBOL Project.
  2. In the Project name field, type ProgramEJB.
  3. Ensure that the 32-bit template is selected, so that a 32-bit project is created. A 32-bit project is required to match the bitism of the enterprise server instance you create to run this application later in the tutorial.
  4. Check Use default location; then click Finish.

    The COBOL Explorer now shows the ProgramEJB project.

Set build configuration properties for ProgramEJB

When Eclipse builds the ProgramEJB project, you want the build action to produce dynamic link (.dll) (Windows) or (UNIX) library file. To ensure this behavior, you need to set the Build Configuration to the All Native Library Files target type:

  1. In the COBOL Explorer, right-click the ProgramEJB project; then select Properties from the context menu.
  2. Expand Micro Focus > Build Configurations, then click Link.
  3. From the Target Type list, select All Native Library Files, then click Apply and Close.

Add BookDemo demonstration files ProgramEJB

  1. From the COBOL Explorer, right-click the ProgramEJB project and select Import > Import from the context menu.

    This opens the Import dialog box.

  2. Expand General and click File System.
  3. Click Next.
  4. Click the Browse button that corresponds to the From directory field, and browse to the %PUBLIC%\Documents\Micro Focus\Visual COBOL\Samples\Interface Mapping Toolkit\ServiceInterfaces\BookDemo (Windows) or (UNIX) directory.
  5. Click Select Folder.
  6. On the list of files, check the following:
    • book.cbl
    • book-rec.cpy
    • bookfile.dat
    • bookfile.idx
  7. Click Finish.

    This adds the files to the project and builds the project automatically.