This chapter identifies the main issues with migrating unmanaged COBOL to .NET managed COBOL.
The majority of COBOL programs can be recompiled as .NET managed code without change.
Some programming techniques and COBOL syntax and features are applicable to unmanaged COBOL only and not to .NET managed COBOL. If you have a COBOL program that uses any of the above, you need to modify the program to use .NET techniques instead, before compiling the program as managed COBOL.
For details on how to migrate Net Express projects to Visual Studio projects, see Backward Compatibility.
The following technologies have migration issues and solutions as follows:
NonCOBOL projects that call COBOL code require a reference to the MicroFocus.COBOL.Runtime assembly.
Any Java interfaces that you created using Net Express can continue to run under Micro Focus Server.
All object references must be defined at level 01, because the compiled code and the runtime system now confirm to .NET rules for type safe code. This conforms with the ISO2002 COBOL standard.
Any Web Services that you created using Net Express can continue to run under Micro Focus Server. These Web Services can interoperate with new .NET managed code. This is recommended.
Web Services that are already deployed and running on Micro Focus Server cannot easily be migrated to a .NET managed environment. Similarly, Web Services that you created using Net Express cannot be deployed directly to a .NET managed environment. You need to migrate your code to .NET before creating the Web Services (for .NET) from the migrated code.
Some COBOL syntax is available for unmanaged COBOL only and not for .NET managed COBOL. If you have a COBOL program that uses this syntax, you need to use .NET techniques instead, before compiling the program as managed COBOL.
The following syntax is restricted to unmanaged COBOL:
Some new syntax is available for .NET managed COBOL and some additional words are now reserved. If your unmanaged code uses words that are now reserved, your code will not compile. You can unreserve the necessary words, by using the REMOVE Compiler directive. See REMOVE.
The following Compiler directives are not supported for .NET managed COBOL:
See Known Errors for details of directives not yet supported.
The following restrictions apply to the use of SQL in .NET managed COBOL:
The following file handling features are not supported in .NET managed COBOL:
Some COBOL functionality is available for unmanaged COBOL only and not for .NET managed COBOL. If you have a COBOL program that uses this functionality, you need to use .NET techniques instead, before compiling the program as managed COBOL.
The following functionality is restricted to unmanaged COBOL:
The following features of OO COBOL are not supported in .NET managed COBOL:
All object references must be defined at level 01, because the compiled code and the runtime system now confirm to .NET rules for type safe code. This conforms with the ISO2002 COBOL standard.
Copyright © 2009 Micro Focus (IP) Ltd. All rights reserved.