How to run command line tools without using a batch file in Inno Setup

Now I understand that "Inno Setup can execute command line tools for you without using a batch file." ( Can installing Inno Setup install a Windows security group? ) It makes sense that she can do this. From my web searches in Inno Setup so far, I cannot find the starting place to figure out how to do this. The full answer may not be needed if I only clarified a little what to look for, it would probably be good enough.

+9
inno-setup
source share
1 answer

This meant that you did not need to create and execute a batch script (with one command), and also not to run the tool on the command line (as shown below):

Exec('cmd.exe', '/c "net localgroup ..."', '', SW_SHOW, ewWaitUntilTerminated, Result); 

But instead, you simply execute the tool:

 Exec('net.exe', 'localgroup ...', '', SW_SHOW, ewWaitUntilTerminated, Result); 

The same applies to the [Run] section:

 [Run] Filename: "{cmd}"; Parameters: "/c ""net localgroup ...""" 

It would be better:

 [Run] Filename: "net.exe"; Parameters: "localgroup ..." 
+19
source share

All Articles