ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   calling external routines (https://www.excelbanter.com/excel-programming/379165-calling-external-routines.html)

Mike

calling external routines
 
I've just converted and old Quickbasic program into excel but i'm stuck on 1
problem which I'm not even sure can be done. I want to call and run an MS DOS
batch file from within a VB macro.

Precisely the batch file is called "importdatafiles.bat' and all it does is
use FTP to tramsfer a few data files from a server to my hard drive.

Is it best (or possible) to call the .bat file and if so how or is there
another way within excel to import the files.

Thanks in advance,

Mike

Mike

calling external routines
 
Apologies for wasting your time, a proper search of previous answers solved
my problem with the Shell command.

Mike

"Mike" wrote:

I've just converted and old Quickbasic program into excel but i'm stuck on 1
problem which I'm not even sure can be done. I want to call and run an MS DOS
batch file from within a VB macro.

Precisely the batch file is called "importdatafiles.bat' and all it does is
use FTP to tramsfer a few data files from a server to my hard drive.

Is it best (or possible) to call the .bat file and if so how or is there
another way within excel to import the files.

Thanks in advance,

Mike


NickHK

calling external routines
 
Mike,
Check out Shell. You can run anything the system considers an executable.

NickHK

"Mike" wrote in message
...
I've just converted and old Quickbasic program into excel but i'm stuck on

1
problem which I'm not even sure can be done. I want to call and run an MS

DOS
batch file from within a VB macro.

Precisely the batch file is called "importdatafiles.bat' and all it does

is
use FTP to tramsfer a few data files from a server to my hard drive.

Is it best (or possible) to call the .bat file and if so how or is there
another way within excel to import the files.

Thanks in advance,

Mike





All times are GMT +1. The time now is 02:11 PM.

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