× 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.


  • Subject: Re: *ENTRY PLIST (was: RE: Pointer not set for location .....)
  • From: rob@xxxxxxxxx
  • Date: Thu, 31 May 2001 11:43:17 -0500


%PARMS again?
Just to rehash an old 'point-of-information', if you have more than one
parm, then I would avoid using %parms.  Because it is possible to omit
passing a parameter withing the middle, while still passing a later
parameter.  This is one good reason to drop using *ENTRY PLIST and use a PI
instead.  If you are addicted to *ENTRY then you may wish to consider
checking each parameter with the following
if %addr(parm1)=*null
* then don't touch this variable!
I used this on a RPGLE program I used as a Command Processing Program with
many optional parameters interspersed.

As far as I am concerned the only good use for %parms is if it is equal to
the total number of parms available then you don't have to check each one
individually.  Or, does it assume that if you send the last parm then you
sent all?

Rob Berendt

==================
A smart person learns from their mistakes,
but a wise person learns from OTHER peoples mistakes.


                                                                                
                                        
                    "Joe Giusto                                                 
                                        
                    \(E-mail\)"               To:     <RPG400-L@midrange.com>   
                                        
                    <juicenetdps@cross        cc:                               
                                        
                    winds.net>                Subject:     *ENTRY PLIST  (was: 
RE: Pointer not set for location .....)  
                    Sent by:                                                    
                                        
                    owner-rpg400-l@mid                                          
                                        
                    range.com                                                   
                                        
                                                                                
                                        
                                                                                
                                        
                    05/31/01 10:31 AM                                           
                                        
                    Please respond to                                           
                                        
                    RPG400-L                                                    
                                        
                                                                                
                                        
                                                                                
                                        





Don't know if this will help, but I usually check the number of %PARMS
passed in *INZSR and move them into working fields only if passed.  Then,
if
it is a critical parm, I can do some kind of notification and if it is an
optional parm, the rest of the program does not care.

This also helps if you want to add a new parm without having to revisit
every program that calls it.

If %parms >= somenumber
Move parm to work field
Set flag for new function
Endif



Joe Giusto II
Programmer/Analyst
Ritz Camera
Beltsville, MD
301-419-3209 x347
410-813-2812 x347


+---
| 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 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.