Browse all forums dedicated to the Rocket® COBOL product family.
Recently active
Problem: Net Express with .NET Calling a user-created file handler in .NET gives error message when compiling: " Failed to find system program "aUserfh" " The CALLFH(aUserfh) directive is set and the file handler is in the project directory. The call to the file handler works if the DLL for the file handler is referenced in the project. However, what if there is the need to compile the source from a script with the directives in a .DIR file? Resolution: Make sure the ILREF"<your assembly name>" directive is also set or included in the .DIR file. This does the equivalent of adding a reference in the Visual Studio IDE. Old KB# 1266#COBOL#netexpress#ServerExpress#RMCOBOL#AcuCobol
Problem: The Opacity allows to get some translucent effect on Windows so that the underlying desktop or windows can be seen. If however the property set on a MDI Clhild Window, it is possible to get unexpected painting problems in the application. Resolution: This is a restriction imposed by Microsoft. Windows and WinForms do not support MDI Child Windows having opacity set. Setting this in the application on MDI the application may have issues and unexpected behaviour when Windows are painted. Old KB# 1244
Problem: When using CBL_ routines and setting flags, it says set bit 0, bit 1, bit 2 etc. Is bit 0 on the left or right end? Resolution: - go to Net Express v5.0 Online Help - type in CBL_OR - select the topic under it 'using to set the value of a bit' - click 'display' - under the 'Parameters' area, click on the link to 'Key' - you are taken to 'Library Routines - Key' - page down - notice the lines: On Exit: Indicates which of the parameters shown are returned on exit. Where bits of one or more bytes are referenced, bit 0 is the least significant (rightmost) bit. Old KB# 1214
Problem: How to make what goes to the Application Output window printable? Resolution: Use the OUTDD compiler directive. Put the full path and filename in the OUTDD compiler directive, then you should be able to print that file. Old KB# 1212
Problem: Release: 5.0: Using the PROFILE directive, but how to get a different target directory for the IPF files? Resolution: Using the COBPRFDIR environment variable to specify an alternative directory. For example: SET COBPRFDIR=C:\\myipfdir Old KB# 1204
Problem: If an HTML "input" control (such text, radio button, etc) has "disabled" attribute, the value of this control doesn't return to CGI program. Resolution: All disabled controls on an HTML page return null/undefined values to the CGI script. A disabled text input field that contains text, for example, does not return any text to the CGI program. Likewise, a disabled radio button that is checked will not return the "on" value to the CGI. This is the default behaviour. Old KB# 1210
Problem: How does ADIS (DISPLAY) decide what colour to use for BLINK. Doing a DISPLAY "HELLO" WITH BLINK how does ADIS decide what colours to use? Resolution: BLINKing (Flashing) text isn't supported by Microsoft's console APIs, so instead getting high intensity background colour eg black becomes grey. Old KB# 1250
Problem: Using REVERSE-VIDEO to display:- display "Hello" at 1101 with REVERSE-VIDEO How does ADIS decide what colours to use? Resolution: ADIS will simple reverse the current backgound and foreground colours. It is not possible to specifically configure ADIS to use any another colour. Old KB# 1248
Problem: When accessing Micro Focus files it is always good practice to check the file status returned after each I/O operation. Resolution: It is possible to create a general COBOL copybook that can be reused in all programs. The following is an example of just such a copybook: 01 (tag)-fstat. 03 (tag)-fs-values. 05 (tag)-fs-key1 pic x(1). 05 (tag)-fs-key2 pic x(1). 05 (tag)-fs-key2-bin redefines &nb
Problem: Compiling a program with mulitple entry points gave the error: 002-R Attempted to redefine symbol when the program was compiled. Resolution: This was caused by the following scenario:- aaaaa.cbl had a program-id of bbbbb aaaaa.cbl also had a an ENTRY POINT called aaaaa. The problem here was generated because the compiler was attempting to create duplicate entry point called aaaaa. Here the program id did not match the source name. The solution was to rename the source file to bbbbb.cbl. The program then compiled cleanly to obj code. Old KB# 1247
Problem: Net Express 5.0 with .NET (base release): System.MissingMethodException on MicroFocus.COBOL.Program.Edited.loadCheck64bitNumericEdited message when running a Net Express 5.0 .NET application Resolution: Net Express 5.0 with .NET (base release): Where there is a combination of a MOVE from an edited data item to a non-edited data item and the CHECKNUM directive. Removing the CHECKNUM directive is a work-around, but installing Net Express 5.0 WrapPack #2 (or higher) will resolve the problem. Old KB# 1235
Problem: Is there a possibility to interface COBOL vs Open Source databases, e.g. MySQL or PostgreSQL? Resolution: Yes, via an ODBC interface provided by Net Express Windows product also provided by Server Express Unix / Linux product (to find in doc files under:OpenESQL) and including a precompiler there is a possibility to interface Open Source databases, e.g. MySQL / PostgreSQL, using ODBC drivers delivered by this Open Source community: a) MySQL: http://www.mysql.org/downloads/connector/odbc/ b) PostgreSQL: http://pgfoundry.org/projects/psqlodbc Old KB# 1240
Problem: When compiled to GNT the application just terminated with no error being output. However when it was built to INT it worked successfully. The last event from a COBOL runtime Consolidated Trace output was an exit program event. Resolution: The top level program in this case was C and it used cobcall to invoke the COBOL. Errors such as this are usually down to the application exceeding stack size. Recursion and local storage all contribute to the stack usage. To increase the stack size by using the /STACK option of the Microsoft Linker. Using another linker then please see the documentation supplied with your linker. Old KB# 1231
Problem: What is the simplest way to set the default ADIS (DISPLAY) colours so that all DISPLAY statements would use the specified colour. Resolution: The simplest way to do this is is simply to clear the screen as follows: display spaces with foreground-colour 3 This sets the default Text colour to CYAN. The online documentation details the number that correspond to colours. Old KB# 1249
Problem: Environment variables can be set at several locations and there was an invisible setting of the environment variable EXTFH which got priority over other settings. The resolution is valid for all environment variables. A status 9/194: "File size too large" was reported even if the settings in EXTFH.cfg configuration file were correct. The EXTFH.cfg settings were: [XFH-DEFAULT] FILEMAXSIZE=8 which allow to access an IDXFORMAT"8" file larger than 4 GByte. But nevertheless the OPEN gives a file status code 9/194. The setting of the environment variable EXTFH in the environment does not change the behaviour. What can cause this? Resolution: The cause for the status is that the EXTFH.cfg could not be read or a false one was found. See also KB: 23553 for "Using Filemon to ensure that the correct version of a file is in use" The resolution here was to delete the <project-name>_RTECFG.obj, because it was no longer used. This obj is linked
Problem: Attempting to install Net Express 4.0 onto a machine that previously had Application server installed. However, the Application Server product was not listed in the 'Add/Remove Programs' in the Control Panel, to enable it to be removed. Error: Setup has detected an installation of Application Server for Net Express 4.0. Net Express 4.0 cannot be installed while Application Server for Net Express 4.0 is present. Resolution: Fully check that no Application Server or Net Express product is installed: - check 'Add/Remove programs' via the Control Panel - check via Windows Explorer for the following folders C:\\Program Files\\Micro Focus\\Net Express OR C:\\Program Files\\Micro Focus\\Application Server OR C:\\mfaslmf - In the Windows Explorer and click on the C
Problem: OFN-ALLOWMULTISELECT flag can be set from the WinAPI GetOpenFileName function to specify that the File Name list box allows multiple selections in the open file dialog box. This however causes dialog box to use the old-style user interface. Resolution: It is documented from the Microsoft MSDN site (http://msdn.microsoft.com) that you need to set also the OFN-EXPLORER flag to have the dialog box to use the Explorer-style user interface. If this flag is not set, then it will use the old-style user interface. Old KB# 1246
Problem: On occasions there is an issue whereby the majority of the COBOL WinForms Toolbox Icons are the same. Unloading the project and reloading it, rebooting the PC does not help. Resolution: Drop to a Visual Studio command prompt and run the command DEVENV /ResetSettings The result will be that the Toolbox Icons are reset to their correct settings. Old KB# 1224
Problem: Net Express 5.0. Is it possible to turn the newline x"0A" character off when writing an XML stream to :cgi:. Resolution: The Net Express 5.0 documentation includes the following: New syntax for select statement is: SELECT xmlfile ASSIGN TO [[NOT] LINE ADVANCING] FILE Of course if "NOT LINE ADVANCING" is specified then no line-feeds would be included in the output. How to write a newline character at the end of the XML stream? This can be achieved as follows: ... select xml-file assign to not line advancing file-name organization is xml document-type is "CompanyTrans.xsd"
Problem: Isam files at client's site were getting corrupted. Some of the files used are large, 1Gb Resolution: The resolution to the problem was to turn the opportunistic looking setting on the Novell server to OFF. Suggestions: 1) Ensure that the Novell Opportunistic Locking setting is turned OFF 2) Add READSEMA=OFF to your current EXTFH.CFG 3) No regular maintenance is done on the ISAM files. Made the strong suggestion that they reorg the files on a regular basis. Old KB# 1221#RMCOBOL#ServerExpress#COBOL#AcuCobol#netexpress
Problem: File and Filename Routines: CBL_CHANGE_DIR, CBL_CHECK_FILE_EXIST, CBL_COPY_FILE, CBL_CREATE_DIR, CBL_DELETE_DIR, CBL_DELETE_FILE, CBL_DIR_SCAN_BEGIN, CBL_DIR_SCAN_END, CBL_DIR_SCAN_READ, CBL_GET_CURRENT_DIR, CBL_JOIN_FILENAME, CBL_RENAME_FILE, CBL_SPLIT_FILENAME, PC_FIND_DRIVES, PC_PRINT_FILE PC_PRINTER_CLOSE, PC_PRINTER_CONTROL, PC_LOAD_BMP, PC_PRINTER_OPEN, PC_PRINTER_WRITE, PC_PRINTER_WRITE_BMP, PC_READ_DRIVE, PC_SET_DRIVE Example: 01 infile-name pic x(20) value '%TMP%/infile'. 01 outfile-name pic x(20) value '%TMP%/outfile'. call 'CBL_COPY_FILE' using infile-name outfile-name. Will fail unless a file with the literal name "%TMP%/infile" exists. Likewise for the outfile name. The CBL_ routines use system API calls, not the command shell, to do their work. Only the command shell "knows"
Problem: Reading System Environment Variables in Net Express Resolution: This demo reads Microsoft Windows TEMP variable: 01 var pic x(256). procedure division. display "TEMP" upon environment-name accept var from environment-value stop run. Old KB# 1217
Problem: Attempting to get the full path/file name of a program that is CALLING the current program by calling the CBL_GET_PROGRAM_INFO routine using call-function 2. However, it might only be returning the program name and not the full path or the file extension. Using this routine to get the COBOL program name can be used for initialising the Consolidated Trace Facility (CBL_CTF_TRACER_GET). Resolution: Below is an example of how to return the full path/filename of the calling program. The first thing to do is to establish the handle for the current program. working-storage section. * 01 call-function pic x(4) comp-5. 01 cblt-prog-info. 05 cblte-gpi-size pic x(4) comp-5. 05 cblte-gpi-flags pic x(4) comp-5. 05 cblte-gpi-handle usage pointer. 05 cblte-gpi-prog-id usage pointer. 05 cblte-gpi-attrs pic x(4) comp-5. 01 name-buf pic x(100). 01 na
Problem: This error has been encountered when trying to compile a .LST program as a Class Library. The message is output when unexpected errors occur during the generation of .NET IL code. Unfortunately, any occurrence of such a message indicates a compiler bug, even though sometimes the immediate reason for the error is a problem in the user program. Even if the user program is in error, the error should be detected at an earlier stage of the compilation process and should then produce a cleaner and more understandable message. Resolution: A subscripted item used as a subscript can generate bad code and may cause the compiler to loop. The fix should be available in the next FixPack for Net Express .NET 5.0 However, attached to this knowledge base article is a hotfix for Net Express .NET 4.0 Attachments: RPI1059463.zip Old KB# 1206
Problem: Release 5.0: Can't create ASP .NET Web App after installing Visual Studio 2005 Service Pack 1. Resolution: Installed Net Express 5.0 with .NET support and have then installed Visual Studio Service Pack 1, and unable to create a new web site/service via the COBOL language. It seems that the Visual Studio 2005 Service Pack 1 installation appears to remove some registry entries which register COBOL with the web project system. Other than the uninstall/reinstall approach (via Windows Add/Remove Programs/Change/Modify option), there is a way to get these entries back by running the following command from the Micro Focus\\Net Express 5.0\\packages directory: regsvr32 cblprj.dll Old KB# 1237
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.