ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Running another program out of excel (https://www.excelbanter.com/excel-programming/396317-running-another-program-out-excel.html)

Mac Lingo[_2_]

Running another program out of excel
 
I want to run "ftp" from VBA Excel. That means starting the program,
executing commands, and getting back the output of the FTP program into VBA
for analysis. I can issue all the commands I need if I'm in the "CMD"
window, but I don't know how to connect it to VBA.

Anyone have any ideas of how to do that?

Mac
Berkeley, CA



JLGWhiz

Running another program out of excel
 
This might help. Not sure.


http://www.kayodeok.btinternet.co.uk...excelhowto.htm

Scroll down to:

How to Open Documents from FTP Site and Save Documents to FTP Site with an
Office XP Program

"Mac Lingo" wrote:

I want to run "ftp" from VBA Excel. That means starting the program,
executing commands, and getting back the output of the FTP program into VBA
for analysis. I can issue all the commands I need if I'm in the "CMD"
window, but I don't know how to connect it to VBA.

Anyone have any ideas of how to do that?

Mac
Berkeley, CA




Mac Lingo[_2_]

No that isn't what I need to do
 

"JLGWhiz"

Thanks for the input. That's interesting, but not what I am trying to do.

I need to read directories off the ftp site to compare dates between what's
stored and what's on my computer to see if a file needs to be backed up to
the site. So I really need to be able to send instructions to the FTP
program and retreive the resulting text.

Mac



John.Greenan

No that isn't what I need to do
 
You have a few options

1. Use the Wininet library - you can look on the msdn and see examples of
how it works. This means writing vba that calls Win32 api functions - not
for beginners.

2. Use vba to create a windows scripting host object and use that. Search
this newsgroup for my name or the topic "Shell Function - Execute DOS
Command" and you can see some examples.

Neither is a great way of doing this, if you are an experienced developer I
suggest option 1, if not then go with option 2.

Good luck.
--
http://www.alignment-systems.com


"Mac Lingo" wrote:


"JLGWhiz"

Thanks for the input. That's interesting, but not what I am trying to do.

I need to read directories off the ftp site to compare dates between what's
stored and what's on my computer to see if a file needs to be backed up to
the site. So I really need to be able to send instructions to the FTP
program and retreive the resulting text.

Mac





All times are GMT +1. The time now is 12:25 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com