1.

Solve : Open Excel program?

Answer»

my batch file coding as follows,

@ECHO OFF
"C:\PROGRAM Files\Microsoft Office\Office\EXCEL.EXE" C:\Testing\Macro1.xls
"C\:Program Files\Microsoft Office\Office11\EXCEL.EXE" C:\Testing\Macro1.xls
EXIT

Some of the P.C the EXCEL program located in folder "Office11" and some located in folder "Office".
If I run the batch file from the command prompt, the message show ' "C:\Program Files\Microsoft Office\Office\EXCEL.EXE" ' is not recognized as an internal or external command, OPERABLE program or batch file
I'm not able to key in any command at the command prompt. Please helpQuote

my batch file coding as follows,

@ECHO OFF
"C:\Program Files\Microsoft Office\Office\EXCEL.EXE" C:\Testing\Macro1.xls
"C\:Program Files\Microsoft Office\Office11\EXCEL.EXE" C:\Testing\Macro1.xls

This can't work.
This should START the Macro1.xls and exit the batchfile:

If the batchfile shall wait:
call "C:\Testing\Macro1.xls"

To check if the macro is in the folder use for example:

if EXIST "C:\Testing\Macro1.xls" ("C:\Testing\Macro1.xls")

hope it helps
uli
if you just want to open the macro1.xls why don't you use this:

Code: [Select]start c:\testing\macro1.xls



Discussion

No Comment Found