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



David,
I had the same issue in the FTPSNDFILE command. 
I added a call to the Remove Message API immediately following a successful
open and specified *NEW and it only removed the last message.
Go to this URL and scan for the call to the QMHRMVPM API, or see the example
below:
http://www.rpgiv.com/cgi-rpg/viewsrc?FILE=QRPGLESRC&LIB=RPGLAB&MBR=FTPSNDFIL
E
 
Here's what it looks like in the code itself.
 ** Remove *LAST generated program message.
C                   CALL      'QMHRMVPM'                
C                   PARM      '*'           CALLSTKE    
C                   PARM      0             CALLSTKCNT  
C                   PARM      '    '        MSGKEY      
C                   PARM      '*NEW'        MSGTORMV    
C                   PARM                    MSGAPIERR   

-Bob Cozzi
www.RPGxTools.com
If everything is under control, you are going too slow.
- Mario Andretti


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx]
On Behalf Of David Gibbs
Sent: Friday, April 22, 2005 10:33 AM
To: RPG400-L@xxxxxxxxxxxx
Subject: Removing CPF4011 -- Buffer length longer than record for member...

Folks:

A co-worker is trying to write a program that does some source code
analysis ... he's got a program defined file that we use to open the
source physical file member (level checks off).

When we open this file we always receive a diagnostic message CPF4011 --
Buffer length longer than record for member xxx.

I realize that this isn't an important error ... and the program is
working fine, but we would really like to be able to remove this message
from the joblog (so as not to confuse our users & support personnel with
insignificant message).  The main reason for this is that the program
that analyzes the source code is going to be called a very frequently
for various source pf lengths.

So far we haven't been able to figure out a way to remove the message.

We tried doing a RCVMSG after the RPG program is called (in the calling
CL), but the message was sent to the RPG program not the CL.

We've also tried running a 'RCVMSG PGMQ(*PRV (*))' from a CL that is
called by the RPG, but that doesn't remove the message either.

Any suggestions?

Thanks!

david

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