Set Up the ProgramRESTAPI Project

Walks you through the process of creating an Enterprise Developer project for the CarsProgram demonstration application, and populating the project with demonstration files.

Create the ProgramRESTAPI project

  1. In Visual Studio, click File > New > Project.
  2. In the Create a new project dialog box, select COBOL from the Language drop-down list.
  3. In the two remaining drop-down lists, select Windows and Enterprise Server respectively.
  4. Select Enterprise Server Application.
  5. Click Next.
  6. Complete the Name and Location fields as follows:
    Name ProgramRESTAPI

    By default, this is the name of both the project and the solution.

    Location c:\tutorials\IMTK
  7. Check Place solution and project in the same directory.
  8. Click Create.

    Visual Studio opens the Solution Explorer for the ProgramRESTAPI solution, showing the ProgramRESTAPI project.

Add CarsProgram demonstration files to the project

Add COBOL source
  1. Right-click the ProgramRESTAPI project, and select Add > Existing Item from the context menu.
  2. Browse to the %PUBLIC%\Documents\Micro Focus\Enterprise Developer\Samples\Interface Mapping Toolkit\ServiceInterfaces\CarsProgram directory.
  3. On the list of files, select the CarsProgram.cbl and cars.cpy files, and then click Add.
Add the cars.xml data file
  1. Using Windows File Explorer or at a command prompt, change to the %PUBLIC%\Documents\Micro Focus\Enterprise Developer\Samples\Interface Mapping Toolkit\ServiceInterfaces\CarsProgram directory.
  2. Copy the cars.xml file to the following location:

    c:\tutorials\IMTK\ProgramRESTAPI\bin\x86\Debug

Set project properties

  1. In the Visual Studio Solution Explorer, right-click the ProgramRESTAPI project, and then select Properties from the context menu.
  2. On the project properties menu ribbon, click COBOL.
  3. In the Additional directives field, type: xmlgen(.\bin\x86\Debug) xmlgen(ws)

Save the ProgramRESTAPI project

  • In the Solution Explorer, select the ProgramRESTAPI project, and then click File > Save ProgramRESTAPI from the Visual Studio main menu.