ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   shell question ? (https://www.excelbanter.com/excel-programming/327066-shell-question.html)

Mathew

shell question ?
 
Hello,

With the Shell function of VBA how can I write the equivalent of :
SubInAcl /output=result.txt /subddirectories c:\


And also I can I do to make "result.txt" be a variable (so I can loop this
cmd on many folder without erase the previous result)

I can only do that Dim RetVal
RetVal = Shell("C:\WINDOWS\SubInAcl.exe", 1)
But it's useless !!!

Can someone help me ?

Cheers
Matthieu



AA2e72E

shell question ?
 
I am not sure what the problem is about passing the parameters. Try:

shellline="C:\WINDOWS\SubInAcl.exe /output=* /subddirectories)
shellline=replace(shellline,"*",yourfilename)
RetVal = Shell(shellline, 1)


"Mathew" wrote:

Hello,

With the Shell function of VBA how can I write the equivalent of :
SubInAcl /output=result.txt /subddirectories c:\


And also I can I do to make "result.txt" be a variable (so I can loop this
cmd on many folder without erase the previous result)

I can only do that Dim RetVal
RetVal = Shell("C:\WINDOWS\SubInAcl.exe", 1)
But it's useless !!!

Can someone help me ?

Cheers
Matthieu





All times are GMT +1. The time now is 01:20 PM.

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