REXX to HTML

Generate REXX-Code as HTML

The ISPF Editor is able to colorize the source code of more than a dozen programming languages. For me this feature is one of the most valuable because it helps understanding the internal code structure and makes reading and analyzing much easier.

When presenting code to the web community as an HTML page without using screenshot images it has always been quite cumbersome to show all the color attributes which often make some details more clear.

So I took a sample routine of W. Schäfer (found on his web page) to generate a HTML file from a REXX program using nearly all ISPF color attributes and adopted it to my needs.

The main enhancements are

  1. The program highlights also single special characters +-*/=<>&^!:%\ similar to ISPF Edit. So now the output should be absolutely equivalent to the default ISPF screen.

  2. It can be invoked as edit macro, as line command in the extended member list of the ISPF Dataset List Utility, or as command via the command line. In latter case the dataset name has to be supplied as invocation parameter.

  3. The generated HTML output can be transferred to the PC via ISPF Workstation Agent.

  4. After transferring to PC the HTML file can be browsed automatically with the application associated to the file extention ".htm".

  5. The coding is fully documented (in broken english).

Here is the program and a sample HTML output using the program source itself:

Extra tip: Robert Prins has developed a fine collection of useful REXX execs that convert z/OS assembler, COBOL, JCL PL/I, REXX, and SuperC output into HTML.

Look at File # 769 R. Prins' edit macros to convert code/text into HTML on the CBTTAPE.ORG site to get a fully matured application which gets continuously improved.

If you have any difficulties with the program or with general concepts behind, feel free to contact me.