Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo


#9 RxFTP Class causes rexx script to hang on return to OS.

David Ashley
Classes (8)

I have recently installed ooRexx V3.0.0 to replace my
unsupported ObjectREXX for Windows.

I've just discovered that the RxFTP extension has been
re-implemented as a Class when ported from ObjectREXX
to ooRexx.

I've re-written my REXX script that was using RxFTP DLL
to use the RxFtp class. The changes required to use the
RxFtp class were minor.

However, after whenever my script attempts to return
the scripting engine, "REXX.EXE", via "return" or
"exit", the script hangs.

I've determined that it is the final "return" where the
script hangs by putting "call trace ?r" before that
"return". It's not a "loop" condition for REXX.EXE is
not consuming the CPU. But no key strokes are echoed or
processed except for "Ctrl-C".

The last RxFtp method executed was "myFtpObj~FtpLogoff()".

Note, this could be a problem with RxSOCK DLL. I've
noticed, but not yet investigated, that some of my
RxSOCK scripts are no longer behaving as they did under
ObjectREXX V2.1.3.

I've attached my script which hangs at the last "return".


  • David Ashley
    David Ashley

    Logged In: YES

    I am not sure but I think that a recent change I made to the
    RxFTP class is causing this symptom. I corrected some code
    in the class and commited it to CVS (version 1.7). Try
    replacing you copy of the class with this one and let me
    know if that corrects the problem.

  • roberto

    Logged In: YES

    David, I'm not so keen about how to get objs from CVS. Can
    you give me the procedure to get the rxftp.cls from the
    Thank you.

  • David Ashley
    David Ashley

    Logged In: YES

    Check out the Open Form discussion with the title rxftp.cls.
    I posted instructions there on how to get the latest copy of
    the rxftp.cls file from the CVS tree.

  • Logged In: NO

    David, I got the last version of rxftp.cls but it still
    doesn't work.
    This is the sample program I've been running. Execution
    stops initializing myftp = .rxftp~new() obj. Any

    / Define the variables for: /
    trace ?r
    server = ""
    userid = "racfid2"
    passwd = "may05oop"
    trclog = "logfile.txt"
    rc = 0
    myftp = .rxftp~new()

    / Start tracing FTP commands and logging of replies /
    rc = myftp~FtpTrace()
    rc = myftp~FtpTraceLog( trclog, "1")
    If rc = 0 then Say " Replies will be written to log
    file: "trclog"."
    Else Say " No writing to log file: "trclog" possible."
    / Define remote host and user to be used during the
    rc = myftp~FtpSetUser(server, userid, passwd)
    If rc = 0 then Say " Connection established."
    Else Call Terminate " Connection failed."
    Transfer an ASCII file to the remote ftp server /
    rc = myftp~FtpPut("sample.rex", "sample.put", "ASCII")
    If rc = 0 then Call Terminate " File has been sent. "
    Else Call Terminate "
    File has NOT been sent."
    / Terminate the file transfer /
    Parse Arg Message
    Say Message
    rc = myftp~FtpLogoff()
    rc = myftp~FtpTraceLogoff()
    rc = myftp~FtpTrace()
    exit rc

  • David Ashley
    David Ashley

    Logged In: YES

    Does your file contain a

    ::requires "rxftp.cls"

    directive? If not, that would be a problem. And that could
    be my fault as the example program in the RxFtp document is
    also missing that directive. Oops :-) This will be corrected
    in the next version of the doc.

    Sorry for the confusion.

  • Logged In: NO


    now it works..... thank you very much for your suggestions.
    I've been an MVS REXX programmer. That's the first time
    I've been using obj REXX.
    I'm afraid I will need your help very soon!!! :-).



Cancel   Add attachments