× 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 have an easier one.  It requires binding a directory.  Here's the code.

H Bnddir('QC2LE')

 * Allows you to execute a CL command from RPG.
D DoCmd           PR            10i 0 ExtProc('system')
D  CmdString                      *   Value
D                                     Options(*String)

D NullString      C                   -1
D Success         C                   0

 /Free
      If DoCmd('CLRPFM MYFILE') <> SUCCESS;
         ... DO SOMETHING
      EndIf;
      ... Do Something
      *InLR = *On;
      Return;
 /End-Free



Michael Schutte
Work 614-492-7419
email  michael_schutte@xxxxxxxxxxxx


                                                                           
             "Lindbom, Joakim"                                             
             <joakim.lindbom@c                                             
             apgemini.com>                                              To 
             Sent by:                  "Midrange Systems Technical         
             midrange-l-bounce         Discussion"                         
             s@xxxxxxxxxxxx            <midrange-l@xxxxxxxxxxxx>           
                                                                        cc 
                                                                           
             03/31/2006 08:10                                      Subject 
             AM                        RE: Clearing a physical file        
                                                                           
                                                                           
             Please respond to                                             
             Midrange Systems                                              
                 Technical                                                 
                Discussion                                                 
             <midrange-l@midra                                             
                 nge.com>                                                  
                                                                           
                                                                           





Just call QCMDEXC with the command as a parameter, something like:

D Cmd            PR                  ExtPgm('QCMDEXC')
D  Command                200A    const
D  Length                      15P 5 const

C                  callp    Cmd('CLRPFM FILE(' %trim(filename) + ')':
200)


/Joakim

________________________________________________________________________
_____
Joakim Lindbom
Capgemini Sweden

There are 10 kinds of people; those who can read binary and those who
can not.

-----Original Message-----
....
Is there coding to clear a physical file within a RPGLE program without
calling a CL program to clear it?
....

This message contains information that may be privileged or confidential
and is the property of the Capgemini Group. It is intended only for the
person to whom it is addressed. If you are not the intended recipient,  you
are not authorized to read, print, retain, copy, disseminate,  distribute,
or use this message or any part thereof. If you receive this  message in
error, please notify the sender immediately and delete all  copies of this
message.


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-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.