1. What is BECOM
  2. What can it do (and changes history)
  3. Distribution
  4. Features
  5. Multipaste in use
  6. BECOM Installation instruction
  7. How to use
  8. Environment
  9. Where to download BECOM
  10. Support
  11. Third parties
  12. Miscellaneous
  13. Other Tools and Utilities from PROGRESS PLUS SOLUTIONS

 

What is BECOM

BECOM - BEtter COde Maker - is a group of programs written on P4GL and available in source-codes, which suppose to make your P4GL code looking better, more clear, readable and understandable. It has several different groups of modules - main modules group (common for everyone and everywhere), rules group (actual programs modifying the source code), and setup group (becom.ini file).

Distribution

BECOM is an open to expand/update its functionality program. You can do it by modifying/adding files of the rules group and reconfiguring the becom.ini file. BECOM is distributed WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Any distribution of modified BECOM code is not allowed unless your changes are included into BECOM original version, which is available for download on: www.progress-plus.com website (see Miscellaneous section where to submit your changes to). All your not included into the original BECOM distributive changes are not allowed for distribution and must be used for personal use only.

What Can It Do

(and changes history)

v.1.4.01, Mar 15, 2004

v.1.4.00, Dec 09, 2003

v.1.03.05, Nov 26, 2003

v.1.03.04, Nov 12, 2003 v.1.03.03, Oct 02, 2003 v.1.03.02, Jul 21, 2003 v.1.03.01, Apr 01, 2003 v1.03.00, Mar 30, 2003: v1.02.02, Feb 10, 2003: v1.02.01, Jan 20, 2003: v1.02.00, Jan 16, 2003: v1.01.01, Dec 09, 2002: v1.01.00, Dec 06, 2002: Initial Version v1.00.00, Dec 04, 2002:

Features

Splits line containing more than one statement:
MESSAGE “a”. RETURN.        
will be:
MESSAGE “a”.
RETURN.
       
changes P4GL statements case to upper-case or to the lower-case:
Define Variable a as int.        
will be:
DEFINE VARIABLE a AS INTEGER.
or:
define variable a as integer.
       
adds/removes spaces before/after brackets ( ) [ ] and commas
cStr = getStr(sourceStr,iParam[i], getNextLineNum(iLineNum)).
      
will be: cStr = getStr( sourceStr, iParam[ i ], getNextLineNum( iLineNum ) ).
replaces short keywords by its full name:
def var a as int.        
will be:
DEFINE VARIABLE a AS INTEGER.
       
aligns source-code blocks:
DO WHILE i < 10:
i = i + 1.
END. will be:
DO WHILE i < 10:
i = i + 1.
END.
aligns IF/THEN/ELSE statements:
IF YES THEN DO:
  MESSAGE "a".
END. ELSE
  IF YES THEN MESSAGE "b". ELSE MESSAGE "c".
IF NOT YES AND NOT NO THEN MESSAGE "d". ELSE MESSAGE "e". will be:
IF YES THEN
DO:
MESSAGE "a".
END.
ELSE
IF YES THEN
MESSAGE "b".
ELSE
MESSAGE "c".
IF NOT YES AND NOT NO THEN
MESSAGE "d".
ELSE
MESSAGE "e".
aligns data definition code sections:
def input param s-value as char no-undo.
def input-output param err-msg as char no-undo.
def output param ferr as log.
will be:
DEFINE INPUT PARAMETER s-value AS CHARACTER NO-UNDO.
DEFINE INPUT-OUTPUT PARAMETER err-msg AS CHARACTER NO-UNDO.
DEFINE OUTPUT PARAMETER ferr AS LOG.
splits long source-code lines into the several short lines:
run CheckField(buffer xattr,if wh:screen-value = "?" then "" else wh:screen-value,input-output err-msg,output ferr).
      
will be:
RUN CheckField( BUFFER xattr, IF wh:SCREEN-VALUE = "?" THEN "" ELSE
wh:SCREEN-VALUE, INPUT-OUTPUT err-msg, OUTPUT ferr ).
removes pseudocomments from the source-code:
{{&postfind}{&*} &norepaint=/*} 
will be:
{{&postfind}{&*} &norepaint=”/*”}
       
adds NO-UNDO to DEFINE VARIABLE and DEFINE PARAMETER statements:
This code:
DEFINE INPUT PARAMETER cMode AS CHARACTER. 
DEFINE VARIABLE lAddNO-UNDO AS LOGICAL INIT TRUE.
DEFINE VARIABLE cCodeCase AS CHARACTER.
DEFINE VARIABLE cmyUndoVariable AS CHARACTER. /* SKIP-NO-UNDO */


will be replaced by:      


DEFINE INPUT PARAMETER cMode    AS CHARACTER NO-UNDO.
DEFINE VARIABLE lAddNO-UNDO     AS LOGICAL   NO-UNDO INITIAL TRUE.
DEFINE VARIABLE cCodeCase       AS CHARACTER NO-UNDO.
DEFINE VARIABLE cmyUndoVariable AS CHARACTER. /* SKIP-NO-UNDO */

Multipaste in use

  1. Select a code block as you do it to copy the block into the clipboard.
  2. Press CTRL-F11 to save the block into the Multipaste clipboard.
  3. Select and copy by CTRL-F11 a few more code blocks.
  4. Press F11. The following window will appear on the screen:
In the window: Left list - copied buffers.
Right editor - a selected buffer contents. The editor is updateable so you can modify it contents right here.
Refresh - refresh the buffers list in a case when you have a few more buffers added by CTRL-F11.
Right-click menu - shows you what you can do with the selected buffer, i.e. Paste it into the editor, Paste and Delete from the buffers list, or Delete the buffer from the list. Multipaste clipboard keeps all its buffers stored between the Progress sessions and even between the system reboots.

BECOM Installation Instruction

  1. Unzip the BECOM.zip into any directory included into your PROPATH.
  2. Open BECOM directory and copy file _ADEEVNT.P into your $DLC\gui\adecomm. Compile it there.
  3. Restart your Progress AB or Procedure editor session. It's ready to use now.

How to use

Environment

Tested so far on Win 98, NT, 2000 Server and Professional, XP, and on Progress v9.1xx.

Where to download BECOM

You can always download the latest available BECOM version from here : http://www.progress-plus.com/dnld.htmSubscribe also to BECOM e-mail list about the new releases, bugs reports, users' opinions etc. : http://www.progress-plus.com/emaillists.htm

Support

We do provide only limited support to BECOM. Full support is available only to BECOM distributed with PRO4m package as part of PRO4m annual maintenance program.

Third Parties

Since June 11, 2003 BECOM is integrated into KSV Editor and can be installed as one single pre configured package from http://www.bulklodd.ru/ksvedit/ .

Miscellaneous

Most of the BECOM source-code is formatted by BECOM. If you have a bug fixed or a new rule written, please send me a copy of what you have done. I'll include it into the BECOM distributive along with your name as the author of the changes done.

Other Tools and Utilities from PROGRESS PLUS SOLUTIONS

PRO4m - Progress Applications/Databases Analysis and ReengineeringProAppmon - Progress Applications MonitoringKTEST - Progress 4GL, Database design and many more online tests- all available on http://www.progress-plus.comAny feedback is appreciated: ysetko@progress-plus.com