I have made a setup and deployment project in C#, Now i have another windows update exe which i want to run and install successfully before it installs my project. I've packaged the exe with my project. How may i run that exe before?
You want to add a Custom Action to the Setup Project that runs the executable. This WalkThrough will take you through getting htat working.
http://msdn.microsoft.com/en-us/library/d9k65z2d(VS.80).aspx
Any other package that should be installed before your own MSI file must be installed by the setup bootstrapper (i.e. the setup.exe file). In order to do so, you should right-click on your setup project, select properties and then pre-requisites. The dialog will list you the components which can be installed by the bootstrapper.
Now, if the component you want to install is in this list, you are done. Otherwise you have to dig deeper into the mechanism of the bootstrapper. Every item in the list has an associated package description stored under
C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\BootStrapper\Packages
for VS 2005 or
C:\Program Files\Microsoft SDKs\Windows\v6.0A\Bootstrapper\Packages
for VS 2008. This package definition basically contains instructions on what to install, how to obtain the component (download url) and how to check whether an installation is necessary.
For custom components you can create your own package definition. If you don't want to do it manually, you can use the Bootstrapper Manifest Generator.
EDIT: If you don't want to go the rather complex but powerful way using the boostrapper you might want to have a look at IExpress. This is a free tool included with MS Windows that allows you to create a self-extracting installation package consisting of multiple components and executing a custom script. IExpress has a graphical UI, but also have a look at the created .sed file for further options.