Printing from EXTRA! Basic.

Attachmate EXTRA! is terminal emulation software to connect to mainframes. Part of this software is a Basic interpreter that allows you to write automation macros that do screenscraping on terminal screens. The scripting language used is called Extra Basic. Scripts have the extension .ebm, which stands for Extra Basic Macro.

This scripting language is a lot like Visual Basic, or QBasic and most code you can simply Copy & Paste. But there are differences.

At work, when extending an old macro (made by a now retired colleague) with printing capabilities I ran into some limitations of Extra Basic.

In QBasic there used to be a command LPRINT to send text to a line printer. Neither Visual Basic or Extra Basic have this command. To print from Visual Basic you use the Printer object, but to print from Extra Basic you need another approach.

It’s not as short as a simple LPRINT, but it will do the trick. Stuff like this makes me want to avoid Extra Basic as much as possible. Use any other more descent language instead to call the Attachmate EXTRA! ActiveX Control.

Leave a Reply

Your email address will not be published. Required fields are marked *