Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

getting out of ftp mode

Status
Not open for further replies.

oldbay

Technical User
Oct 10, 2002
4
US
I have an aspect script that uses a procedure call to perform an ftp. Inside this proc I change modes to ftp (pwmode 1). After retirning from the procedure I try to get back to terminal mode with "pwmode 0" and "pwmode TERMINAL" to no avail. I've stepped through my script in the debugger and nothing happens when it gets to pwmode 0. Am I missing something?
 
Hello,

This code is From the Procomm 4.8 CD.

PWMode FTP
pause 3

FTP LOCAL CHDIR szPath ;Set the local dir. to capture path.
pause 1
Connect FTP szFTP ;Connect to specified FTP site.
pause 2
while $ftpstatus
yield ;Loop while connecting to FTP site.
endwhile
pause 1 ;Let Procomm update its screen.

FTP LOCAL COPYFILE szFile ;Copy (upload) file to FTP site.
while $ftpstatus ;Yield while transferring file.
yield
endwhile
disconnect ;** This Exits FTP Mode
pause 3
pwmode TERMINAL ;** This Sets up Terminal Mode
pause 3


Hank
 
I'm unable to even get pwmode to change to FTP mode (the pwmode command returns failure), so it appears that this command is either totally busted in 4.8 or I'm not implementing it correctly. Procomm was also returning the wrong value for $PWMODE as well.
aspect@aspectscripting.com
 
I have had trouble dialing from the phonebook in 4.8, could the connection directory also be wrecking the environment?

Does anyone know how to implement an ftp without using the connection directory?
 
Played around with this a little more, here's a workaround that should work to switch to FTP mode and then back:

proc main
#include "pw5menu.inc"
menuselect pwmenu _5CHANGE_FTP
pause 3
menuselect pwmenu _5CHANGE_TELNET
endproc
aspect@aspectscripting.com
 
If you are making an anonymous FTP connection, then I think you can use the connectmanual command (but I haven't tested this yet). If you actually have to login to the FTP server, then I believe your only options are using the Connection Directory or having your script bring up the FTP | Manual Connection dialog and using the sendkey and sendkeystr commands to fill out the necessary fields of the dialog.
aspect@aspectscripting.com
 
Knob,

I'll see if I can access the Nortel Server (Unix) via FTP in the Morning and Let you Know.

Hank
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top