I am trying to upload a file to a ftp site using following code.
Problem is file is getting upload but there is no data. Can you plz advise where I am getting lost.
Also my files are with big data, 2+ GB, as far as know this ftp upload will not effect on my cache.dat size. Plz correct if my understanding is not correct.
Set ftp = ##class(%Net.FtpSession).%New()
set sc = ftp.Connect("myFtpServer","myUserID","myPswd")
Set filestream = ##class(%Library.FileCharacterStream).%New()
Set sc = filestream.LinkToFile("\Temp\GaganTest")
set newname = "PrintWaitDetail-14936.xls"
Set sc = ftp.Store(newname,filestream)
Write "Length of file received: ",filestream.Size,!
If 'ftp.Logout() Write "Failed to logout",!