Output File Formats

Supported file formats - .exe and .dll

Each project compiles into a single file (.dll, .so or .exe), or to multiple files of the same file type with one output file for each source file (.dll, .so, .exe, .int, or .gnt). As well as an .lbr file, which contains a collection of .int and .gnt files on Windows, you now can use a .dll as the container for application components.

Building from the command line

To build a Visual Studio solution from the command line:

  1. Click Start > All Programs > Micro Focus Visual COBOL > Tools > Visual COBOL Command Prompt to start the Visual COBOL command prompt.
  2. From the command prompt, navigate to the project directory.
  3. Run the following command to build the solution or the project:
    MSBuild SolutionName.sln

    or:

    MSBuild ProjectName.cblproj

    To view the MSBuild command line options, execute:

    MSBuild /?

Building to multiple output files

Each Visual Studio project compiles into a single file (.dll or .exe).

Instead of an .lbr file, which contained a collection of .int and .gnt files on Windows, you now use a .dll as the container for application components.

Your application can consist of multiple projects, each one building a single output file. To do this, choose from the following techniques:

  • Create multiple projects in your solution each one building to either an .exe or a .dll:
    1. Import the source files by adding one file or a collection of source files to a single project.
    2. Configure each project to produce either an .exe or a .dll by setting the Output type in Properties > myProject > Application.
    3. Build the solution.
  • Split your project into multiple projects in your solution each one building to either an .exe or a .dll:
    1. Use the Create Project from Selection wizard and split the original project into multiple projects in the same solution.
    2. Move each file to a project of its own.
    3. Configure the projects to produce either an .exe or a .dll, and build the solution.
  • Ensure that each project can access any dependent projects, by putting the output files from each project in the same folder.