Browse all forums dedicated to the Rocket® COBOL product family.
Recently active
Problem: This document details what is needed to configure and use the Micro Focus External File Handler, File Tracing. When problems occur while using Micro Focus indexed files, such as data and/or index corruption, you may be asked to enable File Tracing in your application, in order to assist Micro Focus SupportLine personnel in resolving the file issues. After enabling File Tracing, you would run your application in the normal manner with the goal of reproducing the reported error within the indexed files. File Tracing will cause each file handling I-O operation, including data, to be written to the trace file. Micro Focus personnel can then use a special debugging tool to replay the trace file step-by-step using a "before" image of the files being traced. This allows us to locate the particular I-O operation which may have caused the files to become corrupt. For more general information on how to configure the External File Handler and a
Problem: 114 error when loading Net Express. Resolution: Please try the following when you get this error: 1) Open a Net Express command prompt: Start, Programs, Micro Focus Net Express 4.0, Net Express Command Prompt 2) At the command line enter: mfnetx /n If this works, then you probably have a corrupt project (.APP) file. You will need to recreate your project file from scratch. If this is not the issue then look at the following: Lets take a step back and see if anything runs. As before, open a Net Express command prompt and enter "COBOL" at the command line followed by pressing RETURN. Does this give the 114 error ? If not (control and C breaks out of the compiler), then go to the following folder: \\net express\\base\\demo\\adsamp and enter: cobol adsamp anim; Does this work? If it does, then the next step is to ensure that your installation o
Problem: File Type: LINE SEQUENTIAL File Charasteristics: Tab-delimited fields If you view a record via the "Examine" option when animating, or directly via the data file editor in a project, the tab characters are not visible. If, when in the animator, you toggle to view in HEX, it shows spaces where the tab characters are assumed to be. Resolution: To see the tab characters, you need to set the EXPANDTAB runtime configuration switch to OFF. You can do this by setting this in either extfh.cfg (which is the default file-handler configuration file) in the local directory, or by using the EXTFH environment variable to specify a different file-handler configuration file. For example: set EXTFH=C:\\working directory\\my.cfg An example of a config file is as follows (either my.cfg or extfh.cfg): [XFH-DEFAULT] EXPANDTAB=OFF By default EXPANDTAB is ON. This means that if the file is viewed via either the data fi
Problem: Haven't you ever wondered why there is not a simple way of obtaining this, like an intrinsic function, or using INSPECT? Or maybe you have tried something like: working-storage section. 77 ws-name pic x(50). 77 ws-count pic 9(03). procedure division. move "Micro Focus" to ws-name inspect ws-name tallying ws-count for characters
Problem: Error message; "Failed to set up Integrated Development Environment At least one Net Express option failed to install .please exit setup and start install again" Resolution: This can be caused by a problem with the 16-bit subsystem setup on the workstation To check if the 16-bit subsystem is setup properly; - Reboot your workstation to ensure that you are working in a clean environment. *** Please ensure that you are log on as a user that has administrator rights *** - Once the machine is rebooted, move your cursor on your taskbar, right click and bring up Task Manager. - Go to Start/Accessories/Command Prompt to start a Command Prompt. - type the following command; command.com, and press enter. - Under normal circumstances you should see a new process in your Task Manager called NTVDM.EXE - If you have a problem, you should see and error message usually something like; "WOW NTVDM illegal instruction m
Problem: The simplest way is to retrieve the contents of the environment variable USERNAME, as in the code pasted below Others ways are to use the WIN32 APIs GetUSerName or WNetGetUser, as described in MF NeXx sample page getuser.zip : Using WIN 32 Api to get the current user logged using the win 32 api in Cobol getnuser.zip: Using WIN 32 Api to get the current user logged on the network using the win 32 api in cobol Resolution: working-storage section. 01 ENV-value pic x(200). 01 ENV-name. pic x(11) value "USERNAME". &n
Problem: Received an error when trying to open a file. The file status returned is '9 '. What does this mean? Resolution: There are several different file status code values that can be returned from an I/O operation. The default file status codes for this version of COBOL is ANSI'85 (Please read the documentation on the ANS85 compiler directive in the on-line help). The values returned from an I/O operation are in the range '00' through to '49'. The values are returned into a 2 character field. However, the Micro Focus file system also has an extended version of file status codes. To activate these, the NOANS85 compiler directive must be set. The values returned from an I/O operation are returned into a field where the first character is defined as pic x, and the second is defined as pic x comp-x (i.e. hex storage). When an I/O operation fails the first field will always be 9 and
Problem: SQL Server 2000 - global tables work, but need to use local temporary table and those are not working. Resolution: You need to use dynamic SQL and the EXECUTE IMMEDIATE statement to create the temporary table. Use something like the following: declared a string- 01 preptmp pic x(100). move create statement into the string string 'Create table #empbas2 (emp_id char(10), ' ' name varchar(30))' INTO preptmp end-string. used dynamic sql to execute the statement
Problem: Support for CURRENT TIMESTAMP is likely to be required in migrations from Cobol AS/400 with Embedded SQL to Windows platforms using Micro Focus COBOL and OpenESQL. This is an example of a sentence where CURRENT TIMESTAMP is used. In this case, CURRENT TIMESTAMP is substituted by the current date time at execution and used as a value for column TSCOLUMN: EXEC SQL INSERT INTO MYTABLE (COLUMN1, COLUMN2,
Problem: A simple example of mult-threading in COBOL. Resolution: Net Express 4.0 comes supplied with a multi-threading demo in: \\Net Express\\Base\\DEMO\\MTHREAD In addition, the following code sample may be of interest. The demo has two threads: 1) The first thread simply increments a counter and displays the result on the screen. 2) The second thread displays the date and time on the screen. All this goes on whilst the parent updates its own counter. The demo is simple but it does show how to create a thread and to terminate them. Full details can be found in the multi-threading manual. Please note, ADIS (Display/Accept) will interrupt threading so that support should be used with caution. Also, you may find you get "funny" results inside the animator as debugging multiple threads seems tricky. It is always a good idea to run any example from the comm
Problem: The toolbar no longer appears when I launch Net Express. Have opened and closed IDE multiple times and it won't be displayed. Doesn't appear to be minized anywhere. Resolution: From the IDE View -> Dockable Windows , check Toolbar and the Toolbar should now be displayed. Old KB# 6899
Problem: Error when registering a COM Server created using Interface Mapping Toolkit. File not found. Resolution: This error can occur as the COM DLL is dependant on the comservices.dll that resides in the base\\bin where you installed Net Express. If you add base\\bin to your path then the DLL will register correctly. Old KB# 6902
Problem: If you use charset"ebcdic" in a OpenESQL program that uses SQL Server you will get the following error when linking:- error : unresolved external symbol _OESQLEBC@12 Resolution: You need to link your EXE with OESQLEBC.OBJ that is supplied with Net Express Old KB# 6904
Problem: Are there any examples of accessing Excel from COBOL via COM? Resolution: There are examples in Net Express which show how to access Excel and Word from COBOL. The demos can be found in: \\Net Express\\Base\\Demo\\OLEDEMOS\\EXCEL \\Net Express\\Base\\Demo\\OLEDEMOS\\WORD \\Net Express\\Base\\Demo\\OLEDEMOS\\REPORT The downside with OLE is that you are reliant on the vendor of the OLE server for details of the methods they make public. In Microsoft's case this is normally in the Visual BASIC for Applications on-line help. Old KB# 6935
Problem: Receiving a -170 syntax error on SELECT statement containing a WHERE clause. The WHERE clause contains a host variable declared as a group item. Resolution: Although you can use groups of data items as a single host variable in embedded SQL, group items are not permitted in the WHERE clause. Old KB# 6898
Problem: We used to use this program, dfedwg.exe to edit customer datafiles. Is there a NE 4.0 equlivent for this program? Resolution: In Net Express 4.0 the Data Tools are now integrated into the main development environment. Old KB# 6913
Problem: If you follow the "Working with COBOL Projects with .NET" tutorial and get at the steps for adding a Web reference, you may get prompted to open or save after clicking on the Service1 link from the Add Web Reference wizard. Resolution: This problem may actually occur with any service that is selected from the Add Web Reference wizard. This simply means that the file name extension (.asmx) was not mapped to any program or interpreter that processes that file type. Here are the steps to map that file name extension to the program or interpreter: 1. Find out if there are different versions of the MS .NET Framework installed on the machine 2. Determine which one (if there are more than one version) is the latest version by looking at the directory name (e.g. C:\\[Windows directory]\\Microsoft.NET\\Framework\\v1.1.4322 is more recent than C:\\[Windows directory]\\Microsoft.NET\\Framework\\v1.0.3705) 3. Open a command prompt session 4
Problem: The tutorial gives the following steps to add a web reference: 1. Right-click OurConsApp in Solution Explorer, and click Add Web Reference. The Add Web Reference wizard is displayed. If we knew the URL, we could enter it directly in the URL entry field. 2. Click the link for Web Services On The Local Machine. A list of all web services on your machine appears very quickly, showing the Services name and URL. We only have one, Service1. Resolution: If the user does not see anything after clicking the link for Web Services On The Local Machine, it is possible the user does not have a web server running on his/her machine. (This would be the case for Win9x/ME and WinXP Home users) If user is running Windows 2000 or XP Profesionnal, they can install the IIS as follows: 1. Go to Add/Remove Program from Control Panel 2. Click on Add/Remove Windows Components from the left-hand right of the window 3. Check the option for Internet Information Servic
Problem: Net Express 4.0 is not supported under Windows ME Resolution: The supported Windows operating systems are: 98, NT, 2000, XP, Server 2003 Old KB# 6917
Problem: How can I using a filter or mask access each file in a directory. Resolution: The x"91" function 69 call supports this. Old KB# 6910
Problem: How to make the ADO.NET Get Connection Resolution: You can use Sql Assistant to generate the code (Aux tab) - select connected ado radio button and select generic program - insert that code into program and then select GET CONNECTION and insert that code into program as attached example does. Attachments: Program1.cbl Old KB# 6933
Problem: How to be able to have upper and lower case in a PROPERTY Statement in a datafield as property of a class. The problem here is that all letters are automatically changed into capital letters. Resolution: This is COBOL syntax and everything is automatically transformed into capital letters. In order to have lower case or a mix of upper- and lower case letters you can do the following: working-storage section. 01 TestValueAdd1 pic s9(9) comp property as "TestValueAdd1". 01 TestValueAdd2 pic s9(9) comp property as "TestValueAdd2". ******** ^^^^^^^^^^^^^ UPPER- and Lowercase method-id. "InstanceMethod" as "MixedCase". local-storage section. linkage section. Old KB# 6928
Problem: There is no function in Dialog System to load a PDF file. Resolution: A way to do this would be to use the Windows API function ShellExecuteEx to open the PDF file. This obviously requires the Adobe Acrobat Reader to be installed on the machine before it could work. Old KB# 6896
Problem: Can you use free format source code with Oracle's Pro*COBOL? Resolution: We would not recommend the use of free format source with Pro*COBOL. Cobsql does not support use of the SOURCEFORMAT"FREE" compiler directive. If you wish to use free format source code, you must use OpenESQL instead. Old KB# 6891
Problem: Windowsa 2000 Terminal server\\clients Resolution: The clients need access to the HKEY_LOCAL_MACHINE\\Software\\Micro Focus\\ASLMF. From the Terminal server administrator signon RUN REGEDT32 Locate the folder HKEY_LOCAL_MACHINE\\Software\\Micro Focus\\ASLMF high light and select the security pull down menu and permissions. For the user group or everyone uncheck any permission and select the Advanced button. Select the ADD button and high light the group; press OK button. Change the apply to "this key only". Allow all options Select OK Select APPLY Exit regedt32 Old KB# 6923
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.