I am using RAD 2010 and trying to Get a dll from a web site. Using another ftp prog, the dll loads in my calling program with no errors; however, when I use TIDftp.Get with the transferType set to ftBinary, the dll will not load and returns error 998 in the debugger. When I continue in the debugger I get a message Runtime error 217.
I have read that there is a bug in this component. How do I get this method to work?
Alan wrote:
> It was TYPE A.
That is ASCII mode. "TYPE I" is binary mode.
> What is the URL for the download?
http://www.indyproject.org/Sockets/Docs/Indy10Installation.EN.aspx
http://www.indyproject.org/Sockets/Download/DevSnapshot.EN.aspx
--
Remy Lebeau (TeamB)
> {quote:title=Remy Lebeau (TeamB) wrote:}{quote}
> Alan wrote:
>
> > I have the old component and that doesn't work. I tried to toggle
> > before and after connect and I still get a corrupted binary file.
>
> Did you verify that "TYPE A" and "TYPE I" commands are being set to the server
> each time?
>
> > I didn't waste a lot of time trying to get a new component, but the
> > last two times I tried a download, I needed a username and password.
>
> Indy releases are not password-protected.
>
> --
> Remy Lebeau (TeamB)
It was TYPE A.
What is the URL for the download?
Alan wrote:
> I have the old component and that doesn't work. I tried to toggle
> before and after connect and I still get a corrupted binary file.
Did you verify that "TYPE A" and "TYPE I" commands are being set to the server
each time?
> I didn't waste a lot of time trying to get a new component, but the
> last two times I tried a download, I needed a username and password.
Indy releases are not password-protected.
--
Remy Lebeau (TeamB)
> {quote:title=Remy Lebeau (TeamB) wrote:}{quote}
> Alan wrote:
>
> > I have a work around for this. It's not efficient, but what works is
> > to have two components, one for ASCII files and one for binary.
> > Not elegant, or efficient, but works and saves an upgrade.
>
> You don't need two components. You can freely toggle the TransferType property
> between ASCII and Binary on a per-transfer basis as needed.
>
> --
> Remy Lebeau (TeamB)
I have the old component and that doesn't work. I tried to toggle before and after connect and I still get a corrupted binary file. I didn't waste a lot of time trying to get a new component, but the last two times I tried a download, I needed a username and password.
Alan wrote:
> I have a work around for this. It's not efficient, but what works is
> to have two components, one for ASCII files and one for binary.
> Not elegant, or efficient, but works and saves an upgrade.
You don't need two components. You can freely toggle the TransferType property
between ASCII and Binary on a per-transfer basis as needed.
--
Remy Lebeau (TeamB)
> {quote:title=Alan Jordan wrote:}{quote}
> I am using RAD 2010 and trying to Get a dll from a web site. Using another ftp prog, the dll loads in my calling program with no errors; however, when I use TIDftp.Get with the transferType set to ftBinary, the dll will not load and returns error 998 in the debugger. When I continue in the debugger I get a message Runtime error 217.
>
> I have read that there is a bug in this component. How do I get this method to work?
I have a work around for this. It's not efficient, but what works is to have two components, one for ASCII files and one for binary. Not elegant, or efficient, but works and saves an upgrade.
Alan wrote:
> I have read that there is a bug in this component.
If I had to guess, you are likely suffering from the same problem described
in the following discussion thread:
IdFTP changing data size after upload
http://forums2.atozed.com/viewtopic.php?f=7&t=5631
Make sure you are using an up-to-date version of Indy so you have the latest
bug fixes.
--
Remy Lebeau (TeamB)