Write Web Page data from AS400 program
Posted on 2006-10-22
I have an application that is set to write AS400 data to a web page. From the browser address line, I connect via IP address to the AS400 and run my AS400 program (written in RPG ILE) directly from the address line. The program runs and writes the data directly to a web page via CGI script using the "gethtmlifs" command, then displays the web page. I write sections at a time to the web page using the "WrtSection" command. The entire process runs almost instantly.
Here's the problem: I need to loop this program to refresh the data. I have the loop set to 10 seconds in the CL that calls the program. The CL is the program I run from the address line. When I do, the browser window just appends to the bottom. The screen gets longer and longer and the user has to scroll down to see the data. That will not do. I want the loop in my program to refresh the screen with the new values of my data and the user oes not have to touch anything. Essentially, it is displaying production on an assembly line. As units are produced, the counter on the web page will show that by incrementing. As the program loops, the screen should refresh with curent data.
Does anyone know how to refresh the page or tell it to rebuild the page from the top? This is needed urgently so points are available.