Browse all forums dedicated to the Rocket® COBOL product family.
Recently active
Problem: This demo demonstrate how to use the PROFILER utility. Resolution: BUILD W/RELEASE: Net Express v3.1 with fixpacks as of 05/2002 SOURCE FILES: ========== Using the Net Express supplied BEVERAGE HTML demo. REQUIREMENTS: ========== OPERATION: ======== To use the PROFILER utility you need to add the PROFILE compile directive. In this case the directive was added to the Project/Properties directive box. Step 1: Rebuild and run the sample. Step 2: After the completion of the program a file with the extension IPF will be found under the DEBUG directory. To generate the PROFILER report start a Net Express Command Prompt and run the supplied BAT file called PROFILERSAMPLE.BAT. After the completion of Step 2 a new file will be generated under the DEBUG directory with a PRF extension, in this case BEV_H.PRF. This is the report file generated by the PROFILER utility. NOTE: ==== For more details
Problem: Release: 5.0 Error: Runtime Error! Program: ...am Files\\Micro Focus\\Net Express 5.0\\Base\\Bin\\MFNETX.exe abnormal program termination Resolution: Registry entries that are being "marked" as invalid by the Norton One Button Checkup utility are the ones that are made when the Micro Focus OCX files are registered as part of the installation process. These are the files that are located in C:\\Program Files\\Common Files\\Micro Focus. So the likely short-term solution would be to manually register the OCX files again. For example; Open a command prompt Go to C:\\Program Files\\Common Files\\Micro Focus Run this command REGSRV32 valueedit.ocx And so on for every ocx file in that directory. Also, there is a choice NOT to repair these supposed errors. So after re-registering the OCX files should abstain from getting &qu
Problem: Open ESQL supports the WITH HOLD syntax of the DECLARE CURSOR statement. WITH HOLD maintains resources across transactions or multiple units of work. Cursors defined by WITH HOLD will remain open after a COMMIT. This is of course dependent on whether the ODBC interface supports this functionality and whether the ODBC data source has been configured to enable this capability. If WITH HOLD is not supported you will receive a sqlcode of -19520 Connection does not support HOLD cursors on the OPEN CURSOR statement. Resolution: BUILD W/RELEASE: NETExpress 3.1 The program creates two tables in the database and inserts records into both. A cursor is opened on the first table using the 'WITH HOLD' option of the DECLARE CURSOR statement. A row is fetched and then a row from the other table is updated and committed. The next row is fetched from the table, if sucessful the "WITH HOLD" option prevented t
Problem: When compiling a program using Cobsql and the Oracle COBOL precompiler, Pro*COBOL, and the length of the current working directory is over 256 characters, the following error may be returned : * Micro Focus COBSQL Integrated Preprocessor * Net Express Version X.Y * URN AAAPA/ZZ0/00041 * CSQL-I-018: Invoking ORACLE Precompiler/Translator The system cannot find the path specified. * CSQL-F-021: Precompiler did not complete -- Terminating Resolution: The messages contained in that compiler output usually occur due to the length of the path to the current working directory, which causes the command line passed to Pro*COBOL to be too long. The command line should be less than 256 characters. Please make sure to compile (or pre-compile) programs from a shorter directory structure. Old KB# 4371
Problem: This demo demonstrate how to use the FAULTFINDER production debugging utility. FaultFinder is an aid to debugging production applications. Resolution: BUILD W/RELEASE: Net Express v3.1 with fixpacks as of 05/2002 SOURCE FILES: ========== Program Files Description ---------------- ----------------------------------------------------------- faultfind.cbl Resource Files: ---------------- ----------------------------------------------------------- faultfind.cfg Configuration file used to setup FAULTFINDER REQUIREMENTS: ========== Simply do a Rebuild All in the project. OPERATION: ======== 1) From a Command Prompt go to the RELEASE of the project and set the COBCONFIG_ environment variable to; SET COBCONFIG_=FAULTFIND.CFG 2) Run the sample program
Problem: Release: 4.0 How to write XML with repeating elements? Resolution: This article shows how to create an XML file/document that has a repeating element, one that has the maxOccurs="unbounded" attribute. The following is based on the excerpt below from an XML schema file that describes Weather Forecasts. It has 2 main elements, WeatherForecastHeader and WeatherForecast which each have some child elements. In this article you'll also see the word node mentioned to refer to an element. The WeatherForecastHeader occurs only once, but the element named "WeatherForecast" can repeat any number of times as suggested by the attribute maxOccurs="unbounded". <xs:element name="WeatherForecasts"> <xs:complexType> <xs:sequence> <xs:element name="WeatherForecastHeader" maxOccurs="
Problem: When trying to use Interface Toolkit Mapping for generating an EJB on Weblogic the following error appeared: Error 500--Internal Server Error java.rmi.RemoteException: EJB Exception: ; nested exception is: java.lang.NoClassDefFoundError: com/microfocus/cobol/connector/cci/CobolInteractionSpec at weblogic.ejb20.internal.EJBRuntimeUtils.throwRemoteException(EJBRuntimeUtils.java:102) at weblogic.ejb20.internal.BaseEJBHome.handleSystemException(BaseEJBHome.java:296) at weblogic.ejb20.internal.BaseEJBObject.postInvoke(BaseEJBObject.java:284) at weblogic.ejb20.internal.StatelessEJBObject.postInvoke(StatelessEJBObject.java:168) at com.mypackage.MapS19D.MapS19DEJB_1ainp9_EOImpl.S190(MapS19DEJB_1ainp9_EOImpl.java:56) at com.mypackage.MapS19D.MapS19DServlet.performTask(Ljavax.servlet.http.HttpServletRequest;Ljavax.servlet.http.HttpServletResponse;)V(Unknown Source) at com.mypackage.MapS19D.MapS19DServlet.doPost(Ljavax.servlet.http.HttpServletR
Problem: This is a "Mixed Language" 'C' and COBOL project. It was created using NetExpress version 3.1 and Microsoft Visual Studio version 4. It has been tested with Microsoft Visual Studio C/C version 6. The project illustrates how you can incorporate editing, compiling and building 'C' source programs together with COBOL source programs within a common project Resolution: SOURCE FILES: ========== Program Files Description --------------------- --------------------------------------------------------- CNCBLFH.C The initial program of this example. This program displays a couple of messages to the console &
Problem: Release 5.0 .NET: The following statement compiles well even the STRING definition has no length specified. This form is very useful but it is not reflected in the documentation. EXEC ADO DECLARE MYTABLE DATATABLE ( COL1 INT16 NOT NULL, COL2 STRING NOT NULL, COL3 INT16, CONSTRAINT PK_MYTABLE PRIMARY KEY(COL1)) END-EXEC. What are the impacts on using this form? Resolution:
Problem: This project is intended to demonstate how Delphi can be used to call Net Express COBOL Modules. There is an Inprise DELPHI project PROJECT1 which has the Delphi source code included. Please note that it not possible to debug both the Delphi and COBOL components within the same process. Resolution: Attachments: delphi.zip Old KB# 4342
Problem: How to get a machine's MAC address and IP address in a .NET managed COBOL Application? Resolution: The MAC address of a network card is a unique number that is burned into each card produced. It will always be unique and will not be duplicated on any other network card. V2 of the .NET Framework introduced some new classes in the System.Net.NetworkInformation namespace that allows to get details information on the machines network configuration. An example how to use these classes is attached. The code to get the IP and MAC address is: set IPProps to cIPGlobalProperties::"GetIPGlobalProperties"() set label1::"Text" to string::"Concat"("Machine Name = ",IPProps::"HostName","
Problem: Coding a DECLARATIVE section within a COBOL program. Resolution: A useful feature of the COBOL language is the DECLARATIVE section. This section can be used to handle I/O errors when they occur rather than checking the status code after each I/O statement. The following source sample illustrates how to code a DECLARATIVE. select testfile assign "testfile.dat" organization line sequential. fd testfile. 01 tf-record pic x(80). procedure division. declaratives.  
Problem: Example of how the Java Native Interface can be used to call a Net Express COBOL DLL. Resolution: BUILD W/RELEASE: Net Express v3.1 SP1 or later =========== Net Express v4.0 Sun JDK v1.3.xx INTRODUCTION ========== Example of how the Java Native Interface can be used to call a Net Express COBOL DLL. SOURCE FILES: ========== Program Files Description ---------------- ----------------------------------------------------------- HelloWorldImp.cbl Copy Files: ---------------- ------------------------------------------------
Problem: Trying to run a batch file from within a Net Express project. In this example, the batch file contains calls to mfsort. From the command line this all works fine but this does not work from within the IDE. Resolution: Not able to run a bat file directly from a project but there is a possibility to add it as a tool. For example: 1. Click on the Options menu/Customize IDE/Tools 2. Click on "New Tool" and type in a name for the tool, e.g. MFSORT 3. In the "command" field type in the path and name of the bat file, e.g. C:\\tools\\mfsort.bat 4. Click OK to save and then select "Tools" from the IDE menu. 5. Find MFSORT and click on it and the bat file should run. Old KB# 4372
Problem: When trying to remote debug for UNIX from Net Express4.0, at first there is a message "Connecting to the remote machine means that you can view and edit breakpoints" but it appears that actually edit breakpoints cannot be edited. Why is that? Resolution: Problem is that there is the need to have the .idy files locally available to Net Express. If there is no idy at Net Express project, the remote animator can run, but won't give back the option to edit breakpoints. Old KB# 4387
Problem: This problem applies to Net Express 4.0. Resolution: Using XML PARSE and encountering xml-code 200, there is the need to apply All Websync WrapPack v4.0.007 (all07n40.exe) or higher. XML PARSE was returning the wrong xml-code for miscellaneous XML document parsing errors. It should have been returning xml-code 201. Old KB# 4392
Problem: It is generally considered good practice in COBOL to use explicit scope termination statements such as END-IF and END-EVALUATE. Resolution: Using the IMPLICTSCOPE directive to accomplish this. The program:- $set NOIMPLICITSCOPE WARNING(3) working-storage section. 01 ws-data pic x(10). procedure division. start-section section. evaluate true when ws-data = "hhh" continue
Problem: This demo illustrates how to access multiple databases from a single cobol program. The databases are DB2 and Sql*Server. The concept is to use named connections and the SET CONNECTION statement. At the beginning of your program a connection to each database is established. Each CONNECT statement specifies the AS clause which associates a user-defined name to the database connection. When access to a specific database is required the SET CONNECTION statement is issued specifying the name associated with the desired database. All subsequent SQL will access this database until another SET CONNECTION statement is issued. Resolution: BUILD W/RELEASE: Net Express 3.1 The program will prompt you to enter your db2 datasource name, your db2 userid and password, your sql server datasource name and your sql server userid and password. The format for the userid and password is userid.password. If no password is required than merel
Problem: Release: 5.0 .NET / Visual Studio 2005 How to change the Height and Width of a Form at runtime? In a .Net WinForms application there is a possibility to override the defined form size in the Form_loading event that is triggered when a Form is loaded. Resolution: An example is attached that shows how to do this. The project is Visual Studio 2005/Net Express 5 based. In the code there is the need to create an instance of System.Drawing.Size class and pass this to the Form using code such as:- repository. interface S-ComponentModel-IContainer as "System.ComponentModel.IContainer" class System-Windows-Forms-Form as "System.Windows.Forms.Form" class System-ComponentModel-Container as &q
Problem: Apartment threaded COM DLLs built with Interface Mapper not linking with multi-threaded runtime. This is an issue in Net Express 4.0 which is resolved in Net Express 5.0. Resolution: Building an apartment threaded COM DLL using the Interface Mapping Toolkit, the DLL will not be linked to use the multi-threaded COBOL runtime. This is a problem if the client program using a COM DLL is not COBOL, in which case the single-threaded runtime may get loaded. It can also be a problem if the COM DLL code calls any other COBOL programs that are linked to use the multi-threaded runtime. To resolve this, there is the need to edit the deploy.mfscript file located in the NetExpress\\base\\bin directory. Scroll to the bottom of this file where to see <package name="createdll" extension="dll">. Below that, seeing <preoption>-Re</preoption> which can be changed to <preoption>-Rm</preoption>. Save the file and
Problem: Demonstrates the use of the .NET Platform Invoke functionality in order to use the COBOL CALL statement to call entry points and functions within unmanaged Windows dynamic Link Libraries created with Net Express 4.0, Microsoft Visual C/C 6.0 and also to call Windows system API functions. This program also demonstrates the use of the new .NET COBOL structured exception handling syntax to catch run-time exceptions and also shows how to create and use a user-defined exception class. Resolution: BUILD W/RELEASE: Net Express 4.0 with .NET add-on installed. The 'CallUnmanagedDll.zip' file actually contains three different projects which can all be extracted into a single folder on your hard disk. You can create a folder such as 'C:\\CallUnmanagedDll' into which you can extract the entire contents of the zip file, including the subfolder structures '.\\bin\\debug' and '.obj\\debug'. The main source program withi
Problem: A table in XDB has a column with the same name as a reserved word (ex: delete) Using a select statement in your COBOL program like: SELECT delete FROM mftest will get a compiler error: COBES0100S Incorrect SQL statement syntax near DELETE Resolution: In the SELECT statement to qualify the column with the table name should resolve this issue: SELECT mftest.delete FROM mftest Esp. using SQLSERVER to enclose the column names in square brackets: SELECT [delete] FROM mftest Old KB# 4379
Problem: This example demonstrates how to create Windows 32-bit .DLLs from a COBOL program which can be called by a Microsoft Visual Basic program. It also demonstrates how and when to use static and dynamic call-conventions and how to link .DLLs to the Net Express file handler MFFH.OBJ. Resolution: BUILD W/RELEASE: 3.1 INTRODUCTION ========== This example demonstrates how to create Windows 32-bit .DLLs from a COBOL program which can be called by a Microsoft Visual Basic program. It also demonstrates how and when to use static and dynamic call-conventions and how to link .DLLs to the Net Express file handler MFFH.OBJ. The project actually consists of a Visual Basic main program called DEMO1.EXE and a number of Net Express generated .DLLs. DEMO1.EXE displays a single form which interacts with the user. The form contains a number of buttons each of which when pressed will load a COBOL.DLL and call an entry
Problem: This demo shows how you can communicate to a Java Server program using TCP/IP. Resolution: BUILD W/RELEASE: Net Express 4.0 INTRODUCTION ========== This demo shows how you can communicate to a Java Server program using TCPIP. The client COBOL module uses the JAVA/COBOL support to call a Java module that does the comms to the server java program. SOURCE FILES: ========== Program Files Description --------------------- --------------------------------------------------------- TCPServer.java Java Server program UseJavaSockets.cbl COBOL Client program that calls java. SocketClient.java Java client module that performs the comms with the server. REQUIREMENTS: ========== T
Problem: This demo shows how you can use ActiveX Data Objects (ADO) from a Net Express application. For more information on the Methods/Properties and events being used here please see the Microsoft Platform SDK documentation:- http://msdn.microsoft.com/library Resolution: BUILD W/RELEASE: Net Express V3.1 and MDAC 2.5. In order to use this demo you need to have the Microsoft Data Access componants (MDAC) installed. This is available for download at http://www.microsoft.com/data/ This demo has been written and tested using Net Express V3.1 SOURCE FILES: ========== Program Files Description ---------------- ----------------------------------------------------------- ADOData Main ADO Sample Code A DOEvents ADO COM Event
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.