|
Mike, I did something similar to what Scott's described, except for the following: 1. There is a 'global' array where each array element consists of the procedure name and a procedure pointer to that procedure. The LoadProcs() procedure (the equivalent of Scott's init_plugin()) in each service program (there are currently about 6 service programs in all) is passed the pointer to the array, and it loads its procedures and pointers into the array, e.g.: /free SRVPGM1_LoadProcs(ProcArrPtr); SRVPGM2_LoadProcs(ProcArrPtr); SRVPGM3_LoadProcs(ProcArrPtr); SRVPGM4_LoadProcs(ProcArrPtr); SRVPGM5_LoadProcs(ProcArrPtr); SRVPGM5_LoadProcs(ProcArrPtr); /end-free 2. All the called procedures (except the LoadProcs() procedures) are defined as having 4 parameters - 3 pointers and an error structure. The called procedures are all called by name
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.