Connect With Us

Video Walkthrough: Calling RPG From EGL Community Edition

RSS

While IBM's newest business computing language, EGL, is no where near replacing RPG, there's still plenty of FUD surrounding it. For some, it hides unnecessary complexity, and for others, it seems too complex. For still others, it represents an excellent way to rapidly develop Rich Internet Applications (RIAs). Dan Darnell, an independent consultant who specializes in modernizing System i applications through the use of EGL,has noted that you really have to use EGL to appreciate it. The ...

REGISTER NOW TO ACCESS THIS ARTICLE

All registered users get access to premium content on iPro Developer for free.

Already registered? here.

Discuss this Blog Entry 3

Max Harris (not verified)
on Oct 1, 2009
This is a great contribution, Dan, to the effort to promote RichUI EGL as a realistic option for the IBM i. I hope it is widely viewed. I appreciated your mentioning at the end the alternative method of calling the RPG program (from EGL) as an external stored procedure. For some companies or under some circumstances this might be the preferred approach, and it does save you from having to make entries in the build descriptor.
on Oct 1, 2009
My compliments to Dan too, for an informative and nicely done video. Regarding the interface for calling an RPG program from EGL, I couldn't help but note that the standard CGI interface is a lot more streamlined. Just add textbox & button to a static HTML page. Include a reference to any number of AJAX toolkits. Write a javascript function to post the textbox value to the RPG program via CGI when the button is clicked, and write a javascript function to handle the AJAX callback response. No jt400 connection needed. No EGL project definitions or descriptors. No middleware service to write, deploy, or debug under an application server. AJAX w/ CGI would just be a simple interface between the browser and the RPG program. -Nathan
Dan Darnell (not verified)
on Oct 1, 2009
Hi Nathan. Thanks for the feedback. Where EGL shines at directly calling RPG is when you introduce more complex parameter lists. In the article I published ("The EGL Has Landed", System iNews, November 2008) you can see where I am using an EGL program to directly call an RPG program wherein the RPG program has a parameter list consisting of a structure containing an array of structures containing another array of structures and the nested structures have fields with a variety of data types. In my experience nothing comes close to EGL for being able to easily leverage existing RPG code without having to change that RPG code to dumb down parameter lists. I hoped with the video to provide a simple example as a stepping-off point for those who would go on to implement more complex calls. If time allows perhaps I can follow-up with another example such that people can see how EGL and especially EGL with Rich UI simplifies coding all around when dealing with data consisting of a variety of data types and leveraging existing RPG code in a real-world business application. As I am fond of saying, you just have to try EGL to fully appreciate it. You are obviously productive with CGI using HTML, JavaScript, Ajax, RPG for marshaling parameters, configuring the CGIDEV2 module in Apache, etc. I think you are going to be blown away by the ease with which you can rapidly create rich-client apps in EGL where you can really focus on creating business solutions and not on making languages and technologies work together. I hope you have an opportunity to give it a shot...looking forward to hearing more from you! --Dan

Please or Register to post comments.

Blog Archive

Sponsored Introduction Continue on to (or wait seconds) ×