ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   DOS output (https://www.excelbanter.com/excel-programming/415420-dos-output.html)

Anupam Soral

DOS output
 
Is there a way thru which we can run DOS command thru VBA programming in Excel
--
Anupam

Mike H

DOS output
 
Hi,

One way would be to open Notepad and put your Dos commands in a file and
save it as (say) mydos.cmd

Then in Excel try
mydosresponse = Shell("C:\MyDos.cmd", 1)

Have a look at Shell help for what you can do with the second numeric
argument.

Mike

"Anupam Soral" wrote:

Is there a way thru which we can run DOS command thru VBA programming in Excel
--
Anupam



All times are GMT +1. The time now is 07:31 PM.

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