ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Running a batch file from Excel VBA (https://www.excelbanter.com/excel-programming/272135-running-batch-file-excel-vba.html)

verizon

Running a batch file from Excel VBA
 
Hello

My macro creates text files that, subsequently, I would like to
automatically run the batch file which saves them to a remote location
(ftp).

Is it possible for VBA to run an outside program?

W



Hank Scorpio

Running a batch file from Excel VBA
 
On Sun, 20 Jul 2003 08:02:49 GMT, "verizon"
wrote:

Hello

My macro creates text files that, subsequently, I would like to
automatically run the batch file which saves them to a remote location
(ftp).

Is it possible for VBA to run an outside program?


Yes. See on-line help for the Shell function, a summary of which is
below:
--------------------------------
Shell Function

Runs an executable program and returns a Variant (Double) representing
the program's task ID if successful, otherwise it returns zero.

Syntax

Shell(pathname[,windowstyle])
---------------------------------


---------------------------------------------------------
Hank Scorpio
scorpionet who hates spam is at iprimus.com.au (You know what to do.)
* Please keep all replies in this Newsgroup. Thanks! *


All times are GMT +1. The time now is 03:24 AM.

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