View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Gary''s Student Gary''s Student is offline
external usenet poster
 
Posts: 11,058
Default Executing a bat file from Excel

I don't know.....maybe a pair of empty echos???
--
Gary''s Student - gsnu200715


"Mr BT" wrote:

Thanks to both of you.
I forgot to mention, in order for this to work the way I need it to, I need,
I guess, a sendkeys command for the batch file to hit ENTER twice before it
closes.
Is this possible?

Thanks again

Mr BT



"Gary''s Student" wrote in message
...
Sub Macro1()
x = Shell("cmd.exe /c C:\testfile.bat", 1)
End Sub
--
Gary''s Student - gsnu200715


"Mr BT" wrote:

I would like to use a customized menu with a macro that will execute a
batch
file.
I have read over http://www.mvps.org/dmcritchie/excel/shell.htm but I
don't
believe this is what I need.

Thank you.

MrBT