PARAMETERS pcServer,pnPort,pcUser,pcPass,pcLocalName,pcFtpName >> >>SET PROCEDURE TO wwftp addi >> >>LOCAL o as wwFtp >> >>o=create("wwFTP") >> >>o.lPassiveFtp = .T. >> >>o.nFtpPort = pnPort >> >>? o.FTPConnect(pcServer,pcUser,pcPass) >> >>? o.FtpSendFileEx2(pcLocalName,pcFtpName) >> >>o.FtpClose() >> >>o=null >> >>WAIT clear>
with this.oHandler > if .getextendederrorCode()=0 > lcMsg="OK " + .getextendederrormsg() > else > lcMsg="error - "+.getextendederrormsg() > endif > ENDWITH>The resulting string is then logged so I know what went on. One thing I noticed on my website is that if I send files, then quickly after that send some more, after a couple of times it would just kick me off with "too many connections from the same IP in short time" or some such excuse. So perhaps you should connect, do your files, disconnect - IOW keep the connection open, not open/close for every file.