.NET Core Known Issues and Restrictions

The following sections describe limitations that apply when using Enterprise Developer to create applications for use with .NET Core.

.NET Core Version

Enterprise Developer enables you to create COBOL applications to be deployed for use with .NET Core version 3.1.

COBOL Language

A COBOL application that is to be deployed to .NET Core cannot include any of the following features:

  • ACUCOBOL-GT file handling
  • CBL_THREAD_KILL library routine
  • ILVERIFY(CHECK) Compiler directive option
  • JSON PARSE statement
  • STOP RUN statement in secondary threads
  • XML preprocessor or XML Extensions (although the XML PARSE and XML GENERATE statements can be used)

COBOL Run-time Configuration

If you need to use an application configuration file to configure the run-time behavior of an application that will be deployed to .NET Core, the configuration file must be a .dll.config file instead of a .exe.config file as it would be for .NET Framework console application.

Database Access

  • Oracle does not support deployed .NET Core 3.x client applications on SUSE Enterprise Linux accessing Oracle databases.
  • If a COBOL application that is to be deployed to .NET Core needs to use an OpenESQL CONNECT statement, it must use format 6 of the CONNECT statement. See CONNECT for more information.
  • The SQL(DBMAN=ODBC) directive cannot be used in a .NET Core COBOL SQL program. You must use SQL(DBMAN=ADO).[1]

Debugging with a non-COBOL Main Program

By default, COBOL applications in .NET Core projects use the native file handler for their file handling operations. In order for the native file handling functionality to be available when the project is deployed and run, when you publish a .NET Core project the published files include the required native run-time system and file handler (as part of the MicroFocus.COBOL.Runtime package).

If you will be debugging a local .NET Core application on Windows where the main program is not COBOL, for example the main program is C#, you must ensure that an appropriate file handler is used. Failure to do so will result in run-time system error COBRT198 ("Load failure") on the first COBOL file I/O statement.

By default the 32-bit native version of the file handler will be available. For this to be used by your application you need to make sure the project for the main program is built to target the x86 platform.

Alternatively, to avoid any dependency on the native run-time system you can use the .NET file handler. You can switch a .NET Core project to use the .NET file handler rather than the native file handler by specifying the directives CALLFH(EXTFH) and CALLSORT(EXTSM) in the project.

Deploying to Azure .NET

By default, COBOL applications in .NET Core projects use the native file handler for their file handling operations. In order for the native file handling functionality to be available when the project is deployed and run, when you publish a .NET Core project the published files include the required native run-time system and file handler (as part of the MicroFocus.COBOL.Runtime package).

If you will be deploying a .NET Core project to an Azure .NET environment you should instead use the .NET file handler in the project to avoid dependencies that would also require the native C runtime to be deployed by the project. You can switch a .NET Core project to use the .NET file handler rather than the native file handler by specifying the directives CALLFH(EXTFH) and CALLSORT(EXTSM) in the project.

Enterprise Developer Build Tools for Windows

To be able to use Enterprise Developer Build Tools for Windows to build .NET Core projects you must be using Microsoft's Build Tools for Visual Studio 2019. For more information see Using Enterprise Developer Build Tools for Windows to Build .NET Core Projects.

Operating Systems

The following table shows the versions and architectures of the operating systems to which you can deploy .NET Core-targeted COBOL applications that you have published using Enterprise Developer:

Operating System Versions Architecture Run-time Identifier (RID)
Red Hat Enterprise Linux 7+ x64 rhel.7.4-x64
SUSE Enterprise Linux 12 SP2+ x64 sles.12.3-x64
Windows 10 Client Version 1607+ x64 win7-x64
x86 win7-x86
Windows Client 8.1 x64 win81-x64
x86 win81-x86
Windows Server 2012 R2+ x64 win81-x64
x86 win81-x86
Note:

The following operating systems are supported by .NET Core but cannot be used for the deployment of COBOL applications:

  • MacOS
  • Windows and Linux containers running under Docker

Visual Studio Version

Because Enterprise Developer requires .NET Core version 3.1 and .NET Core version 3.1 is not supported by Visual Studio 2017, you must be using Visual Studio 2019 to be able to use Enterprise Developer to create COBOL applications to be deployed for use with .NET Core.

Using Enterprise Developer for Visual Studio 2017 to open a .NET Core-enabled project from a previous version of Enterprise Developer results in an error informing you that the project cannot be opened.

Windows Forms Designer

It is not possible to use the Windows Forms Designer with projects created using the Windows Forms App (.NET Core) project template.