Is there an Easier way to do this because this won't work.
I have 3 batch scripts to run different commands based on a variable.
Basically this variable could be a user server or group. I have a dsquery | DSGET that i have outputting into a text for groups. I then have a function that will read in these users and groups and determines what they are later
I have the import scripted but I don't have the batch script scripted right.
Here is my batch import script as of right now (note i will make it a function later.
I have the shl step to ensure that the shell command is as intended
I run the .bat from cmd.exe and the variable passes properly and the .txt is created when i run the vba code above i get nothing no error or text file. Any sugestions would be appreciated
I have 3 batch scripts to run different commands based on a variable.
Basically this variable could be a user server or group. I have a dsquery | DSGET that i have outputting into a text for groups. I then have a function that will read in these users and groups and determines what they are later
I have the import scripted but I don't have the batch script scripted right.
Here is my batch import script as of right now (note i will make it a function later.
Code:
Sub runbat()
Dim RetVal
var1 = """Domain Admins"""
shl = "C:\TEMP\test.bat " & var1
RetVal = Shell(shl, 1)
End Sub
I have the shl step to ensure that the shell command is as intended
I run the .bat from cmd.exe and the variable passes properly and the .txt is created when i run the vba code above i get nothing no error or text file. Any sugestions would be appreciated