This issue of APIs by Example is brought to you by Carsten Flensburg, who will be providing examples of APIs in future issues about twice a month.
In this issue, he supplies a sample RPG IV program that retrieves the name of the line currently holding the ECS modem. The program uses several APIs, the most notable of which are the Search Hardware Resource Entry (QRZSCHE) and List Configuration Descriptions (QDCLCFGD) APIs.
He includes a simple command and help panel to call the sample RPG IV program, which allows you to quickly verify that the APIs and sample program work.
Download the save file containing the source code.