Jump to content


Member Since 17 Jan 2006
Offline Last Active Dec 02 2009 08:01 PM

Posts I've Made

In Topic: Glovia - Error handling when function is run by Unix script

01 December 2009 - 06:06 PM

Wow, thank you all for detailed feedback! The PROIV and Glovia community/resources are so limited, when I get really stumped, I rely on ProivRC, and have never been let down!

After reviewing the replies yesterday, we have had a Eureka moment!

It so happens we are on Glovia v9 (FYI), and discovered that if we were on v10, we could easily capture the SLERRs, because in v10, they are the same as MSGs - sent to the screen, and always in the same position (how nice). In v9 they are not, so we were given the feedback that what we wanted to do couldn't be done.

Now, for the creative workaround we have devised, inspired by your feedback. The mention of the two global logics spurred the birth of our deceptive solution. Those global logics will either send the error messages to the icons (which we can't readily get to), OR write them to BBERRORS, if it is an XML transaction. SO, we are fooling the system into believing this is an XML transaction (we do this by setting a session variable), which in turn results in the global logics writing the error messages to the BBERRORS table, where we can easily review them.

So, in the beginning of our script, we set the session variable that defines this as an XML transaction, then we call SLGUICPS, next we call our screen function to do the automatic processing we want, and finally at the end of the script we call the SLGUICPE. If there were SLERRs encountered during the transaction, they'll be in BBERRORS, otherwise they'll be in the log file.

Thanks much!!!

Onward, and upward..........


In Topic: Error handling when function is run by Unix script

30 November 2009 - 03:23 PM

We run numerous updates and reports under cron on unix and direct screen output to files by doing the above but adding 2>&1 to the end of the cron line.

/system/scripts/run_this_script.sh > /system/logs/run_this_script.log 2>&1

It throws out all characters sent to the screen including control characters that move the cursor around the screen etc but you can normally see enough when checking for errors. It's also worth putting UMSG's in certain places in your functions at the start to help.

Thanks both Vol & Mark.

We are doing this much.

I think the problem may be that my question is application specific, rather than PROIV specific. I am working with Glovia, and Glovia has a type of error message, SLERR - these messages are not sent to the screen like a UMSG or MSG. They are viewed in a separate warning or error window.

These messages must be written to a temporary table, but are cleared when exiting the screen, I need to find where these are being stored. If there are any other Glovia developers out there with input, thank you in advance!