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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Please help with Shell command statement & arguments 1

Status
Not open for further replies.

vamoose

Programmer
Oct 16, 2005
320
MX
I am trying to combine the following Shell command and arguments into a one line VB statement. Can anyone provide any suggestions. I have tried the FTP -s:CommandFile command and that works fine but I am trying to pass different text files at different times contained in the c:\temp directory. Thank you.

Shell ("FTP -v -n 172.16.7.10")
put c:\temp\ML78071.txt
quit
 
I have tried the FTP -s:CommandFile command and that works fine
So, where is the problem ?
How did you that ?
I am trying to pass different text files at different times
So, write on the fly a command file at each time.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
This would be great, do you possibly have an example I can work from. I am not familiar on how to create, write and save a text file using VBA. Any help would be greatly appreciated. Thank you.
 
I have this working now but I have a few comments/questions:
1. When I open the file as input I cannot use the Print or Write commands. I must open as append to use Print or Write commands. This places the new text on the bottom of the existing text.
2. I cannot get the file to close without saving the changes
3. I need a blank document to be opened, written to, used, then discard the changes returning to a blank document. Am I on the right track ? Thanks.
 
Open the file as Output.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top