|
<< The problem you describe sounds like a design issue to me to be honest. I << wouldn't expect to be passing through values that I don't need personally << (if you see what I mean). Maybe I just don't understand exactly what << you're trying to do here though. Jon, Ultimately, it is a design issue, but the problem is that functions get added to existing programs. When I designed the program, it accepted a set number of parameters. Every program that called that program passed that number of parameters. But then, a new function gets added to that program thats activated by passing in a new parameter. The %parms testing is used so that all other programs that call this program dont have to be changed. Let's say the new parameter is parameter 3. So far, no problem. Now, another new fucntion is added to the program, again activated by a parameter being passed to it (now parameter 4). Any existing programs that are going to be changed to be able to access the new function have to pass in 4 parameters. This means they have to pass in parameter 3 even tho they don't want to activate that function. This is why the If %addr() <> *NULL check is much more consistant to see if you really want to use the parameter that was passed. The %parms doesnt work because you were forced to pass parameter 3 when all you really wanted was parameter 4. Obviously, you can code around this by being aware of the potential problem using %parms. It just seems safer to use the *OMIT and not having to worry about anybody coming along later. I guess part of the problem is that new features are constantly being added to our package and that our package is very modular in nature. A program can easily get called from 10 other programs. Ron +--- | This is the RPG/400 Mailing List! | To submit a new message, send your mail to RPG400-L@midrange.com. | To subscribe to this list send email to RPG400-L-SUB@midrange.com. | To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: david@midrange.com +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.