cancel
Showing results for 
Search instead for 
Did you mean: 

using ftp with a command file as run("ftp -s" + file attachement")

Former Member
0 Kudos

The executing file stop in the command ascii on

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

should be good if you attach all your commands file so we can test the whole file.

Regards.

Abdallah.


Former Member
0 Kudos

From Dos it works but no from powerbuilder 12.5 the running stop to the command ascii on

Regards

Yehuda

Answers (3)

Answers (3)

Former Member
0 Kudos

Have you checked http://www.topwizprogramming.com/freecode_ftpclient.html ?


Regards,


_________________

AUS Julián Tagarro

NeoSistemas SRL

Former Member
0 Kudos

Hi Yehuda,

I tested with PB12.5.2 and it works fine.

I use : run ("ftp -s:c:\temp\ftp_commands.txt remotemachine.domain.com ")

and the file ftp_commands.txt contains :

my_username

my_password

lcd c:\temp

cd /tmp

ascii on

put my_textfile

quit

the remote machine is a Unix machine. Do you have the ':' after the -s /

Regards.

Abdallah.

Former Member
0 Kudos

Tanks, but i work from windows 7 to linox computer ftp without domains,

regards

yehuda

Former Member
0 Kudos

My file fname  is :

open 192.168.20.130

run real

run real

lcd c:\pb125\dag

ascii on

get hazmanat.dat

bye

to get the file i process as :

run("ftp -s" + fname)

Former Member
0 Kudos

I prefer to first build a separate string containing the actual command and then passing that to the run() command.  Makes it easier to determine if the string is (in)correct.  So something basc like:

string     ls_run, ls_filename

ls_run = "ftp -s " + ls_filename

run(ls_run, Minimized!)

Just by looking at your code, I would expect that you are missing a space after the -s" , but without knowing what 'file attachement' looks like, I can't say for sure.

Former Member
0 Kudos

thanks,i will try 

Former Member
0 Kudos

i work in remote,

now, my command ftp works but as, my custumer says that  after executing  it the contains of the file is empty.

regards