How do I delete a file from FTP?

Post Reply
User avatar
Ariston (BR)
Posts: 9
Joined: Fri May 07, 2010 1:42 am
Location: Macapá - Amapá - Brasil
Contact:

How do I delete a file from FTP?

Post by Ariston (BR) »

Hi.

I can already send and receive files. Thanks for those who helped me. Now I need to know how to delete a file from FTP after having downloaded it. Can anyone help me?
Ariston Santos (Macapá-Amapá-Brasil)
FWPPC, Fwh26, xHb, xDev, WorkShop, Php, MySQL.
User avatar
Richard Chidiak
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France
Contact:

Re: How do I delete a file from FTP?

Post by Richard Chidiak »

Hello

This is a sample

oInternet := TInternet():New()
oFTP := TFTP():New( DSITE, oInternet, DUSER, DPASS )

oFTP:DeleteFile(DFIC) // deletes a remote FTP file you must inform the complete address ex /xxx/yyy/myfile.dbf

OFTP:END()
oInternet:End()

Hth

Richard
http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
User avatar
Ariston (BR)
Posts: 9
Joined: Fri May 07, 2010 1:42 am
Location: Macapá - Amapá - Brasil
Contact:

Re: How do I delete a file from FTP?

Post by Ariston (BR) »

Thank you, friend. I am gonna test it now.
Ariston Santos (Macapá-Amapá-Brasil)
FWPPC, Fwh26, xHb, xDev, WorkShop, Php, MySQL.
User avatar
roberio
Posts: 27
Joined: Fri Jul 22, 2011 4:04 am

Re: How do I delete a file from FTP?

Post by roberio »

using the above function .... the following error occurred:

Image

help!
FWHX 11.11 # xHarbour 1.2.1 Rev.9411 ## Borland C++ 5.8.2
Post Reply