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



AFAIK as of V5R2 the %ADDR() BIF of a CONST parameter can only be used in a 
boolean expression and that it still can't be used in an EVAL.
  ----- Original Message ----- 
  From: Bob Cozzi 
  To: 'RPG programming on the AS400 / iSeries' 
  Sent: Thursday, August 31, 2006 3:13 PM
  Subject: RE: Allocate field with options(*nopass :*omit)


  It depends on what release you're targeting the compile.
  If you're on V5.2 or later, I believe it works. It should/does work on V5.3.
  It was supposed to work on V3.7 but nobody complained until long after V5.1 
was
  out.

  -Bob Cozzi
  www.iSeriesTV.com
  Ask your Manager to watch iSeriesTV.com


  -----Original Message-----
  From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On
  Behalf Of Lim Hock-Chai
  Sent: Thursday, August 31, 2006 1:17 PM
  To: RPG programming on the AS400 / iSeries
  Subject: RE: Allocate field with options(*nopass :*omit)

  I get the following compile error when try to assign a pointer to a
  const variable.  Did I do something wrong?  

  RNF7586 20     52 001800  The address of a constant value is used
  incorrectly.

  Below is the program:
       d example         pr                                            
       d  piParm1                      10a   const options(*varsize)   
        /free                                                          
           example('TTTTTTTTTT');                                      
           *inlr = *on;                                                
        /end-free                                                      
                                                                       
        *==============================================================
        * example
        *==============================================================
       p example         B                                             
       d                 pi                                            
       d  piMyStr                      10a   const options(*varsize)   
                                                                       
       d myStr           s             10a   based(myStr_p)            
                                                                       
        /free                                                          
           myStr_p = %addr(piMyStr);                                   
        /end-free                                                      
                                                                       
       p example         E 


  -----Original Message-----
  From: rpg400-l-bounces@xxxxxxxxxxxx
  [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Scott Klement
  Sent: Thursday, August 31, 2006 12:03 PM
  To: RPG programming on the AS400 / iSeries
  Subject: RE: Allocate field with options(*nopass :*omit)


  > 1) I don't think you can do that on a const variable.

  You *can* do it on a CONST variable.  I don't think you SHOULD, but you
  CAN.


  -- 
  This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
  To post a message email: RPG400-L@xxxxxxxxxxxx
  To subscribe, unsubscribe, or change list options,
  visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
  or email: RPG400-L-request@xxxxxxxxxxxx
  Before posting, please take a moment to review the archives
  at http://archive.midrange.com/rpg400-l.


  -- 
  This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
  To post a message email: RPG400-L@xxxxxxxxxxxx
  To subscribe, unsubscribe, or change list options,
  visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
  or email: RPG400-L-request@xxxxxxxxxxxx
  Before posting, please take a moment to review the archives
  at http://archive.midrange.com/rpg400-l.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.