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



I think it's your P spec at the end of the procedure - it's GetDate - not 
Create_CustID...


Jeff Stevens
Mize, Houser & Co. P.A.
913 451 1882
JStevens@xxxxxxxxxxxxxx





RPower@xxxxxxxxxx 
Sent by: rpg400-l-bounces@xxxxxxxxxxxx
07/08/2005 08:59 AM
Please respond to
RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>


To
RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>
cc

Subject
Prototype error






What am I doing wrong?  I'm trying to create a procedure for building a 
customer id, and I'm not getting anywhere.
I get the error:
*RNF7535 30      2 The type and attributes of the parameter do not match 
those
                   of the prototype. 

Here's my code for the prototype and procedure:

      //--------------------------------------------------
      // Procedure name: Create_CustId
      // Purpose:        Creates customer Id.
      // Returns:        Customer Id
      //--------------------------------------------------
     D Create_CustId   PR            22
     D  inStreet                      4S 0
     D  inCivic                      10
     D  inUnit                        5 


         Wccustid = Create_Custid(Wcstreet#:Wccivic#:Wcunit); 

      //--------------------------------------------------
      // Procedure name: Create_CustId
      // Purpose:        Create Customer Id
      // Returns:        Customer Id
      //--------------------------------------------------
     P Create_CustId   B
     D Create_CustId   PI            22
     D  inStreet                      4S 0
     D  inCivic                      10
     D  inUnit                        5
      // Local fields
     D Cust_Id         ds            22
     D  Cust_Street                   4    Overlay(Cust_Id:*Next)
     D  Cust_Civic                   10    Overlay(Cust_Id:*Next)
     D  Cust_Unit                     5    Overlay(Cust_Id:*Next)
     D  Cust_Seq                      3    Overlay(Cust_Id:*Next)
     D retField        s             22
     D Valid                           N
      /FREE
         Cust_Street = %Editc(inStreet:'X');
         Cust_Civic = inCivic;
         Cust_Unit = inUnit;
         Seq = 1;
         Cust_Seq = %Editc(Seq:'X');
         retField = Cust_Id;
         // Check that we don't already have this id, if we do, increase 
the seq number portion
         Valid = *Off;
         DoW Valid = *Off;
           Chain retField Wcustomer;
           If %Found(Wcustomer);
             Seq += 1;
             Cust_Seq = %Editc(Seq:'X');
             retField = Cust_Id;
           Else;
             Valid = *On;
           EndIf;
         EndDo;
         Return retField;
      /END-FREE
     P GetDate         E 

Ron Power
Programmer
Information Services
City Of St. John's, NL
P.O. Box 908
St. John's, NL
A1C 5M2
Tel: 709-576-8132
Email: rpower@xxxxxxxxxx
Website: http://www.stjohns.ca/
___________________________________________________________________________
Success is going from failure to failure without a loss of enthusiasm. - 
Sir Winston Churchill

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.