Turning off ScreenUpdating alone reduced the time per file to 2 secs! invoke ExcelObject "setScreenUpdating" using by value 0.
↧
Forum Post: RE: Performance degradation of Native COBOL access to Excel 2016
↧
Forum Post: RE: Calling NATIVE COBOL from cobjvm
I have been goggling around "Java TUXEDO" and see no evidence of TUXEDO which would be using "their own executable that instantiates the JVM (kind of like cobjrun does) but with more stuff going on"... Would you elaborate on this. I found in TUXEDO DOC the PATH has to point to the bin directory of the installed JRE ... which would indicate TUXEDO/java use the java launcher ... !? Also, taking this URL docs.oracle.com/.../pgapi.html Would you be trying to invoke JVM COBOL here? ... rply = myAppCtxt.tpcall("SVC", rqStr, TPNOTIME|TPSIGRSTRT); /* !? Invoke JVM COBOL here !? */ rtn = TuxAppContextUtil.tpappthrterm(); ... I don't have right now TUXEDO on line and never played so far with TUXEDO/Java ... docs.oracle.com/.../javaservadmin.html Oracle Tuxedo Java Server Administration docs.oracle.com/.../pgint.html Introduction to Oracle Tuxedo Java Programming docs.oracle.com/.../index.html Introduction to Oracle Tuxedo Java Programming Regards Yvon
↧
↧
Forum Post: VS 2017 not found VC 3.0
Today when installing an update of VS 2017 prof.(15.6.6), when restarting VS2007, it does not find anything referred to VC 3.0. I tried to repair VC 3.0, and run createenv.bat, but VS 2017 doesn't find anything about VC 3.0 and doesn't appear as installed in "about Microdoft Visual Studio 2017". What can I do to fix it?
↧
Forum Post: RE: calling procedural cobol from java I get error
It looks like PATH does not have \bin or \bin64 on it (use bin64 for you 64bit version of java). Have you used the createnv.bat (or setupenv.bat) before executing "java DatabaseBmw"?
↧
Forum Post: RE: VS 2017 not found VC 3.0
Two thoughts come to mind. 1. Does Visual COBOL appear in your programs and features (Apps and Features if Windows 10)? 2. If it does load Visual COBOL (Visual Studio), select tools ~ Import and Export Settings. Select Reset all settings ~ Next ~ You can save your settings if you want or select No ~ then select General ~ Finish Hopefully your Visual COBOL is now available again. Neil
↧
↧
Forum Post: CobJVM and MAVEN
Anyone have success with using the cobol compiler in -j mode under maven? I want to build a solution including both java classes and CobJVM source and I would like it to all be in one JAR file. ideally, I would like to have COBOL call java and also have java call COBOL.
↧
Forum Post: Deleted from N records in delete 'where current of' in cursor for update and SQLCODE = -100
I have a cursor for update in microfocus, with connection to a database of db2. In the readings of the fetch, always read a single row, but when I'm going to do the delete / update of this with a where current of the value of the SQLCODE is a -100 and N rows are deleted or modified, respectively, instead of the corresponding current . Any solution? Thanks. For example: $set sql(CHECKSINGLETON) $set constant driverClass "com.ibm.db2.jcc.DB2Driver" $set constant databaseURL "jdbc:db2://localhost:50000/sample:retrieveMessagesFromServerOnGetMessage=true;user=MFADMIN;password=MicroFocus42;" IDENTIFICATION DIVISION. *-----------------------. PROGRAM-ID. ATB984. AUTHOR. AA DATE-WRITTEN. 20180412 DATE-COMPILED. DATA DIVISION. *-------------. WORKING-STORAGE SECTION. *-----------------------. 01 FILLER PIC X(25) VALUE 'COMIENZO WORKING ATB984'. 01 NOMBRE-MODULO PIC X(08) VALUE 'ATB984 '. 01 ATC990 PIC X(08) VALUE 'ATC990 '. 01 db2-data. 05 campo1 pic X(8). 05 campo2 pic X(8). 05 campo3 pic X(8). 05 campo4 pic X(8). 01 VARIABLES-WORKING. 05 LONG-MENS PIC 9(02) VALUE 77. 05 MENS-SEND-TEXT PIC X(77) VALUE SPACES. 05 LIT-BD-INF-REA PIC X(24) VALUE 'B.D. INFO. REARRANQUES'. 05 LIT-TBINFREA PIC X(08) VALUE 'TBINFREA'. 05 TEXTO-ERROR-BD. 10 NOMBRE-BD PIC X(24). 10 NOMBRE-TABLA PIC X(11). 10 OPERACION PIC X(20). 10 CODIGO-ERROR. 15 FILLER PIC X(10) VALUE 'SQLCODE : '. 15 NUMERO-ERROR PIC S9(10) SIGN IS LEADING SEPARATE. *+----------------------------------------------+ * VARIABLES PROPIAS DEL PROGRAMA *+----------------------------------------------+ 01 DATOS-SYSIN. 05 NOMBRE-PROG PIC X(08) VALUE SPACES. 05 CADENA-PROG PIC X(04) VALUE SPACES. 01 CONTA-REG PIC 9(04) VALUE ZERO. *+--------------------------------------------------------------+ * FLAG DEL PROGRAMA *+--------------------------------------------------------------+ * 01 FG-NO-MAS-REGISTROS PIC 9 VALUE 0. 88 NO-MAS-REGISTROS VALUE 1. * * +--------------------------------------------------------------+ * INCORPORACION DE LA AREA DE COMUNICACION DEL 'SQL' * +--------------------------------------------------------------+ EXEC SQL INCLUDE SQLCA END-EXEC. * +--------------------------------------------------------------+ * DECLARACION DEL CURSOR1 * +--------------------------------------------------------------+ EXEC SQL DECLARE CURSOR1 CURSOR FOR SELECT campo1, campo2, campo3, campo4 FROM TABLADB2.ADMIN_EMP where campo2 = 100 FOR UPDATE END-EXEC. * VARIABLES-AUXILIARES 01 FILLER PIC X(25) VALUE 'FINAL WORKING ATB984'. * +--------------------------------------------------------------+ * P R O C E D U R E D I V I S I O N * =================================== * +--------------------------------------------------------------+ PROCEDURE DIVISION. 1-INICIO-ATB984. *---------------. EXEC SQL CONNECT USING "DRIVER=com.ibm.db2.jcc.DB2Driver;URL=jdbc:db2://localhost:50000/sample:retrieveMessagesFromServerOnGetMessage=true;user=MFADMIN;password=MicroFocus42;" END-EXEC if sqlcode not equal 0 display "Connection Error. SQLCODE=" sqlcode stop run end-if PERFORM 3-PROCESO THRU 3-PROCESO-FIN UNTIL NO-MAS-REGISTROS. 3-PROCESO. *---------. PERFORM 31-ABRIR-CURSOR THRU 31-ABRIR-CURSOR-FIN. PERFORM 32-FETCH-CURSOR THRU 32-FETCH-CURSOR-FIN. PERFORM 33-BORRAR-REGISTROS THRU 33-BORRAR-REGISTROS-FIN UNTIL NO-MAS-REGISTROS. PERFORM 34-CERRAR-CURSOR THRU 34-CERRAR-CURSOR-FIN. EXEC SQL COMMIT END-EXEC MOVE ZERO TO CONTA-REG. 3-PROCESO-FIN. *-------------. EXIT. 31-ABRIR-CURSOR. *---------------. EXEC SQL OPEN CURSOR1 END-EXEC. IF SQLCODE NOT EQUAL 0 PERFORM 4-FINAL THRU 4-FINAL-FIN. 31-ABRIR-CURSOR-FIN. *-----------------------. EXIT. 32-FETCH-CURSOR. *---------------. EXEC SQL FETCH CURSOR1 INTO :campo1, :campo2, :campo3, :campo4 END-EXEC. DISPLAY 'FETCH CURSOR' DISPLAY sqlerrd(3) --> 1 every time IF SQLCODE EQUAL +100 MOVE 1 TO FG-NO-MAS-REGISTROS ELSE IF SQLCODE NOT EQUAL 0 PERFORM 4-FINAL THRU 4-FINAL-FIN. 32-FETCH-CURSOR-FIN. *---------------------. EXIT. 33-BORRAR-REGISTROS. *-------------------. EXEC SQL DELETE FROM TABLADB2.admin_emp WHERE CURRENT OF CURSOR1 END-EXEC. DISPLAY 'DELETE CURSOR' DISPLAY sqlerrd(3) --> n every time IF SQLCODE EQUAL 0 ADD 1 TO CONTA-REG ELSE PERFORM 4-FINAL THRU 4-FINAL-FIN end-if PERFORM 32-FETCH-CURSOR THRU 32-FETCH-CURSOR-FIN. 33-BORRAR-REGISTROS-FIN. *-----------------------. EXIT. 34-CERRAR-CURSOR. *----------------. EXEC SQL CLOSE CURSOR1 END-EXEC. IF SQLCODE NOT EQUAL 0 PERFORM 4-FINAL THRU 4-FINAL-FIN. 34-CERRAR-CURSOR-FIN. *----------------------. EXIT. 4-FINAL. *-------. MOVE LIT-BD-INF-REA TO NOMBRE-BD. MOVE LIT-TBINFREA TO NOMBRE-TABLA. exec sql commit end-exec exec sql disconnect end-exec. MOVE SQLCODE TO NUMERO-ERROR. DISPLAY 'PROGRAMA ATB984 HA FINALIZADO: ', NUMERO-ERROR. STOP RUN. 4-FINAL-FIN. *-----------. EXIT. OpenESQL-Error. *---------------. display "SQL Error = " sqlstate " " sqlcode stop run exit. The index of the table is campo1,campo2, campo3 and the delete "where current" deletes all records that meet the where, in a single time and the SQLCODE = -100, something that for me is wrong. Could you help me get the delete done by the current and get a correct SQLCODE? Thanks.
↧
Forum Post: RE: Deleted from N records in delete 'where current of' in cursor for update and SQLCODE = -100
I tested this with an example of my own and cannot reproduce the behavior you are reporting. I am using Visual COBOL for Eclipse 3.0 on Windows against the DB2 Express Samples database. I connect to the database, open a cursor that returns a number of rows and for each fetch I am doing a DELETE WHERE CURRENT OF statement and it results in SQLCODE=0. I am not actually committing the deletions but the DELETE does appear to work correctly. Example: $set SQL(DBMAN=JDBC CHECKSINGLETON) $set constant driverClass "com.ibm.db2.jcc.DB2Driver" $set constant databaseURL "jdbc:db2://localhost:50000/sample:retrieveMessagesFromServerOnGetMessage=true;user=CRG;password=mypass;" working-storage section. * Include the SQL Communications Area. This includes the * definitions of SQLCODE, etc EXEC SQL INCLUDE SQLCA END-EXEC. 01 DCLEMP. 03 EMP-EMPNO PIC X(6). 03 EMP-FIRSTNME PIC X(12). 03 EMP-LASTNAME PIC X(15). 01 connectionstring pic x(300) value spaces. *> after an sql error this has the full message text 01 MFSQLMESSAGETEXT PIC X(250). procedure division. EXEC SQL WHENEVER SQLERROR perform OpenESQL-Error END-EXEC move "Driver=" & driverClass & ";URL=" & databaseURL to connectionstring TYPE6 exec sql TYPE6 connect using :connectionstring TYPE6 end-exec if sqlcode not = 0 display "Error: cannot connect " display sqlcode display sqlerrmc goback end-if move 200000 to EMP-EMPNO EXEC SQL DECLARE usercursor CURSOR FOR SELECT A.EMPNO ,A.FIRSTNME ,A.LASTNAME FROM CRG.EMP A WHERE (A.EMPNO >= :EMP-EMPNO) for update END-EXEC EXEC SQL OPEN usercursor END-EXEC PERFORM UNTIL SQLCODE Process data from the Fetch IF SQLCODE = 0 DISPLAY emp-empno display emp-lastname EXEC SQL DELETE FROM CRG.EMP WHERE CURRENT OF usercursor END-EXEC END-IF END-PERFORM EXEC SQL CLOSE usercursor END-EXEC EXEC SQL DISCONNECT CURRENT END-EXEC goback. *> Default sql error routine / modify to stop program if needed OpenESQL-Error Section. display "SQL Error = " sqlstate " " sqlcode display MFSQLMESSAGETEXT .
↧
Forum Post: Pro*COBOL and Informix: cannot find "INFORMIXDIR"
I need to compile my COBOL file with Informix Embedded SQL, but preprocessor fails because of this error: CSQL-F-012: INFORMIXDIR must be set for Informix Support I'm using Visual Studio 2017. The variable is correctly set in Windows' environment variables. The preprocessor is "Oracle Pro*COBOL(COBSQL), with "COBSQLTYPE" directive set to INFORMIX-NEW. How can I solve the problem?
↧
↧
Forum Post: Calling Unmanaged COBOL from Managed COBOL: System.AccessViolationException
I'm following the tutorial to call unmanaged COBOL code from managed COBOL, but I get this exception: "System.AccessViolationException". What is causing it?
↧
Forum Post: RE: Pro*COBOL and Informix: cannot find "INFORMIXDIR"
Can you run the Informix preprocessor directly from the command line? This would tell you if Informix is set up correctly outside of Visual Studio. What do you have this variable set to? It should contain a full path to the Informix installation folder. Open up your project properties page and on the Application tab click on the Environment button and try adding INFORMIXDIR to the list of environment variables for the project.
↧
Forum Post: RE: Calling Unmanaged COBOL from Managed COBOL: System.AccessViolationException
I am not sure which tutorial it is to which you are referring? Can you provide a link to the docs that you are using? At what point do you get that error?
↧
Forum Post: RE: Pro*COBOL and Informix: cannot find "INFORMIXDIR"
What version of INFORMIX are you running? Basically, this error indicates that COBSQL can't find the Informix's ESQLCOB Precompiler (esqlcob.exe) in "%INFORMIXDIR%\lib". Is the Informix's ESQLCOB Precompiler present - "%INFORMIXDIR%\lib\esqlcob.exe"?
↧
↧
Forum Post: Searching for fix2kset.exe to install old MF Cobol 4.0
Hi, I'm new here and have a question for the older COBOL developers among us :) I have an old version of Micro Focus COBOL, it's version 4.0 for Windows 95/NT, including the License Key dongle which you have to put on the parallel port of your computer. Recently, my old computer died, and I'm trying to install this COBOL compiler on another system with Windows XP. When running SETUP, it results in an error: Execution Error, file "LOG", error code 114, pc=0, call=21, seq=0 (signal=11) While searching on the internet for a clue, I read that I Micro Focus / Merant made a patch to make an installation possible after Y2K. It should also work on Windows XP. The patch file is called fix2kset.exe, and in the past it could be downloaded from the MF/Merant ftp site, but not anymore. It's nowhere to find. Can anyone help me finding this particular patch file? Any help is much appreciated! Kind Regards, Peter
↧
Forum Post: RE: Calling Unmanaged COBOL from Managed COBOL: System.AccessViolationException
I get the error on the "CALL" instruction: "call "prog2" using custRecord" I found the tutorial here: community.microfocus.com/.../visual-cobol-for-visual-studio-getting-started-with-solutions-projects-and-the-cobol-call-statement-pinvoke Thank you!!
↧
Forum Post: RE: Pro*COBOL and Informix: cannot find "INFORMIXDIR"
Ok this is the problem! I thought that the problem was that it could not read the variable... but I was wrong! The variable content is absolutely correct, but the COBOL precompiler is missing. Can I take the chance and ask you where I can find it? I'm very new ad this... Thank you very much!
↧
Forum Post: Winforms DataGridView to Excel
Hi, Is there a quick (.NET) way to output data from a Winform Datagridview "straight" into Excel? Many thanks Neil.
↧
↧
Forum Post: RE: Pro*COBOL and Informix: cannot find "INFORMIXDIR"
The ESQLCOB precompiler is an Informix product and not a Micro Focus one. You should contact Informix about downloading and installing the correct product for your system.
↧
Forum Post: RE: Pro*COBOL and Informix: cannot find "INFORMIXDIR"
Thank you. I have the C version, but cannot find anywhere the COBOL one
↧
Forum Post: Adding a signature file
We are using Visual COBOL on a Red Hat Linux Machine. Our programs are text based UI. We have been asked to start using a signature file on our checks. Can someone tell us how you would do this? What kind of code to use and what format the signature should be in? We use cups to print.
↧