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



Dan,

 The problem is that MCH3601 Pointer not set for location referenced is
thrown.  Here are some code snippents:

Compile:
CRTCMD CMD(XTEST )                                  
       PGM(XTEST )                                  
       ALLOW(*IPGM *BPGM *IMOD *BMOD *IREXX *BREXX)  

CMD        PROMPT( 'Testing retrieve parms' )              
                                                           
PARM       P1        TYPE( *CHAR ) LEN( 1 ) MIN( 1 )     + 
                     PROMPT( 'Parm 1' )                  + 
                     EXPR( *YES )                          
                                                           
PARM       P2        TYPE( *CHAR ) LEN( 1 )              + 
                     RTNVAL( *YES )                      + 
                     PROMPT( 'Return Parm - P2' )          
                                                           
PARM       P3        TYPE( *CHAR ) LEN( 1 )              + 
                     RTNVAL( *YES )                      + 
                     PROMPT( 'Return Parm - P3' )          
                                                           
PARM       P4        TYPE( *CHAR ) LEN( 1 )              + 
                     RTNVAL( *YES )                      + 
                     PROMPT( 'Return Parm - P4' )          


/*  Test return values in command - CPP */
XTEST: PGM      ( &P1 &P2 &P3 &P4)  
                                    
       dcl      &p1   *char 1       
       dcl      &p2   *char 1       
       dcl      &p3   *char 1       
       dcl      &p4   *char 1       
                                    
       chgvar   &p2  '2'            
       chgvar   &p3  '3'            
       chgvar   &p4  '4'            
                                    
endpgm                              
-------------
xtestc:  pgm                                          
                                                      
       dcl      &p1   *char 1  'a'                    
       dcl      &p2   *char 1                         
       dcl      &p3   *char 1                         
                                                      
             XTEST      P1( &p1 )  P2( &p2 ) P3( &p3 )
                                                      
             SNDPGMMSG  MSG(&p1 |> &p2 |> &p3)        
                                                      
endpgm                                                
-----------

 I origianlly had through parm &p3.  When I added parm &P4, MCH3601 is
generated.  I hope that this makes it clearer.

 -mark



Original Message:
-----------------
From: Dan Bale dbale@xxxxxxxxxxxxx
Date: Wed, 22 Sep 2004 08:59:16 -0400
To: midrange-l@xxxxxxxxxxxx
Subject: RE: Omitting retrieve values on a command


> -----Original Message-----
> From: midrange-l-bounces@xxxxxxxxxxxx / M. Lazarus
> Sent: Tuesday, September 21, 2004 9:47 PM
>
>   I have created a "retrieve" command as a front end to some values in a
> file.  Is there a way to shield existing programs from a change to the
> command?  Normally it's easy to add parms to a command without affecting
> existing programs - as long as the keywords used in those programs still
> exist.  But on a retrieve type command, if I add a parm then the pointer
> has nowhere to go!
>
>   Is there an elegant way to get around this limitation or do I
> have to go
> into all the programs, add the parms and associated variables and
> recompile?  TIA.

I guess I'm not seeing the problem, Mark.  Are the new parms "required
parms"?  If you add parms to any command that is already being used in your
apps, those parms just won't be "retrieved" for those programs.  I use
RTVMBRD in many applications, but only use a small number of its parms.
What happens if IBM adds another retrievable parm to that command?  Will I
have to recompile all my programs?

db

--------------------------------------------------------------------
mail2web - Check your email from the web at
http://mail2web.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.