Mark- 29 Posted August 23, 2024 (edited) Hello, Using the sample project to fetch file size. Binary Mode is checked and the error returned for "Size" and "FileSize" button is: I verified "Binary" was true. Ideas? Thanks, Mark Edited August 23, 2024 by Mark- Share this post Link to post
Angus Robertson 591 Posted August 23, 2024 V8.01 is 14 years old, unsupported. Angus Share this post Link to post
Mark- 29 Posted August 23, 2024 (edited) 3 hours ago, Angus Robertson said: V8.01 is 14 years old, unsupported. That is the version of the sample program. Is there a newer version of the sample program? Edited August 23, 2024 by Mark- Share this post Link to post
Angus Robertson 591 Posted August 23, 2024 That non-SSL sample is no longer part of the main distribution, the SSL version was last updated two weeks ago in SVN. But the FTP commands have not changed in many years. Angus 1 Share this post Link to post
Mark- 29 Posted August 23, 2024 (edited) Using version: 8.65 Just a follow up for anyone wanting to fetch a file size. I could not get the Async call to work. VerifyFTP.UserName:=<UserName>; VerifyFTP.PassWord:=<Password>; VerifyFTP.HostName:=<HostName>; VerifyFTP.HostDirName:=<HostDirName>; VerifyFTP.HostFileName:=<HostFileName>; try VerifyFTP.Connect; VerifyFTP.Cwd; VerifyFTP.TypeBinary; VerifyFTP.Size; finally VerifyFTP.Quit; ShowMessage(VerifyFTP.SizeResult.ToString); end; Thanks François and Angus. Edited August 23, 2024 by Mark- Share this post Link to post
FPiette 387 Posted August 23, 2024 To send the "binary" information to the server, you must call TypeSet or TypeSetAsync. Share this post Link to post
Mark- 29 Posted August 23, 2024 44 minutes ago, FPiette said: To send the "binary" information to the server, you must call TypeSet or TypeSetAsync. Right, the Async (FileSize, calls FileSizeAsync) function to fetch a file size does not do that, in the version I am using. Share this post Link to post