NetTalk Central

Author Topic: RUN(something,1) following FTP_DownloadFile generates ERROR()  (Read 6565 times)

mtabakin

  • Jr. Member
  • **
  • Posts: 53
    • View Profile
    • Email
Greetings:

I've come across a strange situation and was wondering whether anyone has experienced the same situation or has any insight.

Recently I added the NetTalk 4 FTP_Downloadfile, FTP_UploadFile and FTP_Files_Procedure to a legacy 5.5 application per the documentation. Following the call to FTP_DownloadFile I use a Clarion RUN(someprogram,1 ) command to run another clarion application.

The FTP successfully downloads the file with no error messages posted AND the RUN command successfully runs the other program. However immediately following the RUN command 9 times out of 10 an ERRORCODE() and ERROR() are set to 30 "Entry Not Found". The RUNCODE() in all cases is 0.

I've checked ERRORCODE() and ERROR() immediately before the call to FTP_DownloadFile, immediately after FTP_DownloadFile and before the RUN and they show NO errors posted.

If I DO NOT call FTP_DownloadFile, then the ERRORCODE() and ERROR() following the RUN are never set. It is reproducable 9 times out of 10, that is, there definitely appears to be a cause and effect between FTP_DownloadFile and the Clarion RUN. Everything regarding FTP, RUN and other code seems to be operating correctly and I wouldn't have noticed this it were not for checking ERROR() and ERRORCODE(). If the RUN is returning a RUNCODE() of 0, I can't figure out why calling FTP prior to the RUN is generating the ERRORCODE(), especially since it is 0 just before the RUN (and just after the FTP_DownloadFile). A successful RUN should clear ERROR() and ERRORCODE() but appear not to IF FTP_DownloadFile was called just before.

I don't want to make a big deal out of nothing but it does make me wonder what the interaction between FTP and RUN is and whether NetTalk might be causing other interactions I'm not aware of. As I said everything seems to be operating normally otherwise. 

Thanks

Mike Tabakin

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: RUN(something,1) following FTP_DownloadFile generates ERROR()
« Reply #1 on: April 07, 2010, 10:26:48 PM »
Hi Mike,

There is no FTP code running between your call to RUN and the following line, so if, the errorcode is 0 before, then it can only be the Run command that is setting it if it is non-zero after.

That said, without seeing the actual code, it's impossible to speculate as to the possible cause.

cheers
Bruce

mtabakin

  • Jr. Member
  • **
  • Posts: 53
    • View Profile
    • Email
Re: RUN(something,1) following FTP_DownloadFile generates ERROR()
« Reply #2 on: April 08, 2010, 06:42:12 AM »
Bruce,

I agree that it must be the RUN command because there is no code between FTP_DownloadFile(.......) and RUN(....) but the call to RUN is always the same and a error is only generated if you do FTP_DownloadFile.

My client was just a little concerned that there was a "problem with NetTalk stuff"  that might cause other syst3em problems, although as I said perviously there is no indication of ant problem and I do have procedures using NetTalk e-mail functionality. I'm not loosing sleep over this but I said I would check it out.

Have a good day.

Mike Tabakin