I'm working for a custom installer developed in Visual Studio 2008 (Setup & Deployment > Setup project) for a C# project. I'd like to run a batch file (*.bat) after installation is finished. How can I do that?
相关问题
- How does the setup bootstrapper detect if prerequi
- Sorting 3 numbers without branching [closed]
- Graphics.DrawImage() - Throws out of memory except
- Generic Generics in Managed C++
- Why am I getting UnauthorizedAccessException on th
You can run a batch file using
cmd.exe
, anyway it is what executes batch files.Start it this way:
cmd.exe /c <path-to-batch>\batchfile.bat
.You will have to extend the Installer class and override the Committed event.
Here is an example. Hope you will be able to find how to run a .bat file in C#.
Custom Install Action is another option. Here is a similar thread for that.