How to create an installer from Visual Studio
1. Open the Visual Studio solution
|Open the solution for which you want to create the install package.
2. Add an Advanced Installer Project to the solution
|Once the Visual Studio solution is loaded:
|By default, when adding an Advanced Installer Project, the build output of the solution will not be automatically added to the installer project, to do this you must:
|Press "Add Project Output" button
|Select the “Primary Output” and “References”
|Press [ OK ]
|Following these steps, Advanced Installer Extension for Visual Studio adds in the installer project all application references except the Microsoft .NET assemblies.
3. Create the first install package
|In Visual Studio select "Build" > "Build Solution" option to start the build.
|After the build is completed successfully, it will create two main files: HelloWorld.exe which is the output from the C# project and Installer Project.msi which is
|the installation package.
4. Edit the installer project
|Using the Advanced Installer Project viewer, you can edit basic information about your installer like Product Details, Launch Conditions, Install Parameters, and
|Let's suppose we have an Enterprise edition of Advanced Installer. By default, the installer project will be created based on a Freeware license. Since we want to use
|features from the Enterprise edition, like selecting a theme for the installation dialogs, we will need to upgrade our project type:
|Now, that we have an Enterprise project we have full access to all the available Advanced Installer Enterprise features.
|Visual Studio will ask you if you want to reload the installer project since it was modified. Press the [ Yes ] button.
5. Add another Visual Studio Project to the solution
|If an Advanced Installer Project is added to a solution, it will automatically import the build output and all useful information related to the projects from the solution.
|If later, the existing projects are modified, or another project is added to the solution the import operation must be redone.
|Let's add a new Visual Studio project to the solution:
6. Create the final install package
|Include the second project in the installer package:
|The newly created installer will contain all the projects from the solution.
7. Automatically import .VDPROJ files (optional)
|If you have solutions that contain old Visual Studio Deployment projects (.vdproj) you can automatically convert them to an Advanced Installer project and have it included in your
|solution, replacing the old VDPROJ. Just open the solution in Visual Studio, with our Advanced Installer VS extension installed, and VS will prompt you to accept the conversion from
|VDPROJ to AIPROJ (Advanced Installer VS project).
|The new project Advanced Installer project will contain all the resources from the old VDPROJ. If you want to customize it more just use the "Edit in Advanced Installer" button,
|available when you open the .aip file in Visual Studio.
8. Add project output of a .NET core project to your setup project (optional)
|If you have a .NET Core project in your Visual Studio solution, here is how to include its output in the setup project:
|Go to the “Files and Folders" section of the Installer Project, click on "Add Project Output" and check "Publish Profile" option:
|If there is no publish profile previusly created, you will be asked to create one:
|Next, you will be asked where do you want to publish:
|Choose "Folder" option in order to publish your application to a local folder.
|Then, provide the path to the publish folder:
|After publishing the application, go back to "Add Project Output" and select the newly created publish profile:
|The final step is to build the Advanced Installer project in order to update the output files.
It might also interest you
How to install Inno Studio Script
How to create an installer using Inno Setup