|
>> Usually when you call a routine in a service program, you want the next line of code to be able to detect an error. You don't want some external procedure being called... Actually I kinda like it for just that purpose Scott. The main line calls a generic routine to perform some processing. Some of the potential "errors" that can be signaled by that routine are not errors to the caller - they are perhaps an expected condition (like "not found" when I'm adding a new record). Using a call back approach one generic routine can do zero error handling (Proc ptr is passed as null) - generic error handling (proc pointer not passed at all) or caller specific/extended error handling (proc ptr is passed). The proc doesn't have to be external - it can be local to the main line. Jon Paris Partner400
As an Amazon Associate we earn from qualifying purchases.
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.