× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Here's my deal.  I have the following sub procs which interface with java
methods, and if a java exception is thrown I want to catch it in my
RPGMail_xxxx sub procs, parse it, and relay a more friendly error back to
the calling program.  Once I have "caught" the "percolated" error is there a
way to 'un-catch' it so the error continues to percolate up to the next
calling program so it errors out with its MONITOR, and once errored out goes
to look in some additional error sub procs I have setup?  


    Monitor;
       email = RPGMail_new();
       RPGMail_addAddress(email: 'FROM': from: 'Aaron Bartell');
       RPGMail_addAddress(email: 'TO': to: 'Larry Boy');

       RPGMail_setSubject(email: 'This is the subject line');

       RPGMail_setBodyFile(email: '/tmp/news.html': 'text/html');

       RPGMail_addFileAttachment(email: '/tmp/Example3.xml': ' ': ' ');

       RPGMail_setSMTPHost(email: 'smtp.mycompany.com');
       RPGMail_setSMTPPort(email: '25');

       RPGMail_send(email); 
    On-Error;
       errors = RPGMail_getErrors();
    EndMon;

I have tried producing errors with callbacks, but if an error is encountered
on RPGMail_addFileAttachment, I don't have a way to say don't process the
next three sub proc calls (RPGMail_setSMTPHost, RPGMail_setSMTPPort,
RPGMail_send).  I could return a value on each sub proc call to indicate
whether or not it errored out, but that makes the code look really messy
('If' statements everywhere).

Thanks for any help you can give,
Aaron Bartell

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.