Marc's Place


Tools for the IBM iSeries AS400 and i5

E$LNG - Language tools

E$LNG is a quick and cheap solution to make your display (DSPF) and printer files (PRTF) language independent.

Literal independent, actually. The software extracts all literals that are text and stores them in a message file, for each language you define. The original text is then replaced by a MSGID or MSGCON statement. An extensive programmer's manual is included in the download.

  • Context sensitive extraction (3 levels). This means that, for example, the word 'file' can have multiple meanings and will be saved multiple times instead of only once.
  • You choose whether text will be replaced by MSGID or MSGCON.
  • Multiple languages (i.e. message files) at the same time.
  • Fast
  • No modification of original work. Only copies are created.
  • Extracted text is also saved in a file so when it is extracted a second time it will keep the same message id.
  • Support of subfiles and printer files. Normally in subfiles and printer files only MSGCON is allowed. E$LNG generates RPG/400 source code for the extracted text so it can be retrieved dynamically.
  • Listings of extracted text and what message id they have become and where they are stored.

How does it work? Like this. You create a display file and type text on it. Using the single quotes, reserve space for the literal text, for example: 'Customer ', because in another language you may need more than 8 characters. Next, you run E$LNG and a new source file will be created, containing a copy of the original display file. This copy is then modified and can be compiled. Text is extracted and, depending on the parameter settings, stored in each defined language message file. You have to translate the text for every language yourself, of course. After compilation, add the library containing the message file to your library list and run your program.

The download contains a binary *SAVF, saved with V5R2M0, which you can upload to your iSeries and then get the contents with RSTLIB E$LNG.
The SAVF does not contain compiled applications, you have to do that yourself.

Source files have been updated to ILE source file format, and tested, in July 2018.

Manuals can be found here .

Download E$LNG

Buy me a coffee-1

E$LIB - Library with routines

E$LIB is set of programs which make programming easier and your sources easier to read. Also a few /COPY members to standardise certain parts of your source. An extensive programmer's manual is included in the download.
DATE calculations
With this program one can calculate with dates, convert them, etc.. You can add days, convert dates to week numbers, day numbers, alphanumeric, etc, etc... The program accepts alphanumeric parameters so it can also be used in CL-programs.
FIELD listings
With this software you can do various things. Fixed options are listings of all fields of a file or a listing of key-fields only. Other options are RPG/400 or DDS output to a file from a file so one does not have to type every MOVE(L) instruction. Within SEU you can copy this output directly into your source with F15. You can also add your own output queries to this software (like a plug-in). You need QUERY/400 for this software.
'DIR' command
With this command you can list objects from various libraries that have been changed or created since a certain date.
A standard RPG/400 program skeleton with simple subfile handling.
/COPY members
Using these your sources will be more uniform.
COPYRIGHT data structure
Your copyright source lines in color.
Data-structures for interactive RPG/400 programs
This copy member has the following data structures:
  • A display device DS with the most common fields.
  • A second program DS
  • Function key definitions. Using these you do not need indicators to handle function keys. You can refer directly to the function key pressed: ##KEY IFEQ F10 instead of *IN10 IFEQ *ON.
Data-structures for all RPG/400 programs
This copy member has the following data structures:
  • A program DS with the most common fields used.
  • A printer device DS so you can test the overflow without using an indicator, etc.
  • A message handling DS for use with the message handling routine.
Message handling routine
A standard way of sending messages to the calling program. Use this with the message queue defined in DEFAULT#.
Formatting routines
Alignment routines, amount formatting routine, German Umlaut conversion routine, routine to convert ISO HTML characters (&...), routines to remove whitespace and characters like '-' and '/', find and replace routine, a.o.
Routine to read out ';'-separated data
With this routine you can retrieve each column from a record of file that contains data separated by some character (tab, colon, semi-colon, etc.). These types of files come mostly from external FTP sources.
Routines set the system date
With these routines you have a universal system date structure. Fields like SYSYMD, SYSMDY, SYSYY, SYSMM and SYSDD can be used throughout the program. Depending on the routine used, you get the actual system date or the time shifted job-date. The time shifted job-date is retrieved from a data area which should be set every night by maintenance routines.

The download contains a binary *SAVF, saved with V5R2M0, which you can upload to your iSeries and then get the contents with RSTLIB E$LIB.
The SAVF does not contain compiled applications, you have to do that yourself.

Source files have been updated to ILE source file format, and tested, in July 2018.

Manuals can be found here .

Download E$LIB

Buy me a coffee-1

E$EXP - Source code expander

E$EXP is a software package that implements a multi-level /COPY or $COPY statement in any source member type (RPG, DSPF, PRTF, TXT, CL, CLP, etc.). A programmer's manual is included in the download.

Every programming language has a statement to include source files at compile time. Only some languages can include sources one level deep, like RPG/400. A /COPY statement within a /COPY member is not possible. With E$EXP it is! Furthermore, for RPG sources, E$EXP works like CRTRPTPGM but faster. So you can create 'object'-sources where all coding specs (F,E,I,C lines) are present. E$EXP will place them in the correct part of the expanded source.
So, using E$EXP, you can
  • Include sources up to 9999 levels deep.
  • Specify all types of RPG source lines in RPG /COPY members. They will be placed at the correct position.
  • Use it with any source file type (CLP, DSPF, PRTF, etc).
And it
  • Does not modify your original sources. Instead, it expands the originals in a new sources in a separate source file.
  • Is fast.


Include RPG sourcecode:
This is the statement:

C .........
C .........
* or use
C .........

And this is an example member MEMBER:

C Eval px1 = customer
C Eval px2 = order
C Eval px3 = orderline
C Eval px4 = 0
C Eval px5 = 0

Include DSPF sourcecode:
This is the statement:

* Include standard header format

And this is an example member DSPFMBR:

A 1 13'/'
A 1 19'/'
A 1 68'/'
A 2 2'-----------------------------------
A ------------------------------------
A ---------'

Include CLP sourcecode:
This is the statement:

pgm parm(&src &where)
dcl &src *char 10
dcl &where *char 20

/* Include standard declarations */

And this is an example member CLPMBR:

dcl &loglvl *char 1
dcl &logsev *dec (2 0)
dcl &logcl *char 10
dcl &stsmsg *char 7
dcl &wrkstn *char 10

The download contains a binary *SAVF, saved with V5R2M0, which you can upload to your iSeries and then get the contents with RSTLIB E$EXP.
The SAVF does not contain compiled applications, you have to do that yourself.

Source files have been updated to ILE source file format, and tested, in July 2018.

Manuals can be found here .

Download E$EXP

Buy me a coffee-1

E$API - Application Programming Interface

E$API is a software package you can use to link any other AS/400 software to your own software. The goal is that you can make your software independent of almost anything you can think of.
  • You can make your program data independent by calling an API which then calls a program that retrieves the data and passes it back to your program.
  • Or you can link various modules of one software package to one another.
  • Or you can call other API's in the background.
  • Or you can link your big software package (or only parts of it; it is up to you) to one or more other software packages.
An example
You are building trade software for international use. That means you need a file with country codes and a file with currency codes and rates. The customer who is going to use this software probably also has a financial system which already has these tables. What you can do is:
  • Build your own tables and incorporate these in your software. Not such a good idea because someone has to look after these tables to make sure they are up to date and equal to the tables of the other software package.
  • Acces the tables of the financial package directly from your program. Also not such a good idea, because when these tables change, you need a notification of the third party developer that your software needs to be recompiled or worse, changed.
  • Use the API's of the financial package (if any). Better, but when these change, you also need to change your software.
All this is fine, of course, when this trade package you are building is only to be sold to one customer. But what when you sell it (yeah!) to more customers who all have different financial packages? Or other third party software that needs to be linked to yours, for example a warehousing package. With the mentioned three options your head will fall off in no time.

But here comes E$API. With E$API you are not dependent of others! Your point of view changes because you do not have to ask yourself where to get the data, you tell others what data you need. The only thing that needs to be done is to write small programs that can access the data of the other software package, sort of a plug-in.

These small programs are then called by E$API. If you make the needed parameters public, other people also can write these small programs and make them known to E$API.

Now you can sell your trade software without worrying about changes others make to linked software packages. The only thing you need to change are these small programs, the plug-ins, whose only function is to retrieve data from somewhere.

And when a customer decides to throw his current software package into a trash and decides to buy another package, he will call you in panic that all of a sudden your software does not work anymore. You tell him or her to stay calm and you connect to his computer.

You change one E$API connect-definition, write new small programs to retrieve the data of the new third-party software, call your customer and tell him that your software never failed in the first place, copy the new small program to your computer and add a line in your advertisement that your trade software can also interface with product X.

Sounds confusing? Well it is....on the other hand, if you get the meaning, it is not.

Download E$API

Buy me a coffee-1

E$INS - Installer for your software

E$INS is a universal software updater. It can update almost any AS/400 library. This installer was written to facilitate the update process of new releases of (parts of) big software packages where logical files are added and removed, fields are added to files, field attributes that change, fields that disappear, etc..

Using this software you have (as a customer or as a software producer) an easy to use software installation tool. The tool can handle up to five libraries at once which contain new software and uses these five libraries to update one to five target libraries.

The installer will save the old objects in a separate library and then overwrites the old ones with the new ones. File dependencies are checked and handled.

Inside the download is a detailed PDM listing which shows which sources are of which type, so it can get you going.

Download E$INS

Buy me a coffee-1

E$SEC - Serial or Code number

E$SEC offers you a framework to add copyright protection to your software. It uses a simple alphabetic shift to code a license number, but you can make it more difficult if you like.

The software consists of commands and programs to maintain product registration at a customers' AS/400. And it has sources you need to incorporate in your RPG and CLP programs. An easy way to accomplish that is to use E$EXP (second entry on this page).

If someone then installs your software without the correct license key, a display will tell the user his software is not properly installed.

Download E$SEC

Buy me a coffee-1

buy me something-2
© 1997- Marc Vos (and others)   -   Privacy Statement   -    Contact Me

On this website, Google Analytics is used to track visitor statistics. These are anonymised data about the number of visitors, which pages they visit on this site, from which regions they visit, which web browsers they use, etc.. You will also see non-personalised ads via Google AdSense. Cookies from Paddle or Paypal are placed when you click on a 'Buy now!' or 'Donate!' button, and possible cookies from Disqus when you use that system to comment on one or more blogposts.
Privacy Statement