Home  »  Articles  »  .Net Framework  »

Creating a setup file of a c#.net application

 Posted By : Manoranjan SahooPosted Date : 05/08/2011 03:14:23 PM Category : .Net Framework Points : 8 (Rs 3.00)

In this article I am going to show how to create a setup file for a C#.Net application using a standard Visual Studio Setup wizard.

We are developing software application for client. Finally we have to provide our application to the end-user.  So we need to create setup file to deploy the application in client machine. So here i am going to provide the information about the setup file creation.

To create setup file follow the below steps :

Step 1: First we need to open the C#.Net project/solution (for which you want to create setup file). Goto 'File -> Open -> Project/Solution' (or Ctrl+Shift+O):

Step 2 :  After opening the C#.Net project/solution goto next steps.

Step 3 : Now you have to add a setup project to the current project/solution. Goto 'File -> Add -> New Project...' :

Setup wizard 1

Step4 : In the 'Project types' list, go to 'Other Projects -> Setup and Deployment' and select the 'Setup Wizard' template:

As you see there are many 'Setup and Deployment' project types and you can create just a blank setup project and customize it by yourself, But In this article I am going to show the use of setup wizard, which is much  easier than others for beginners.

Step 5 : Now give attention towards the setup wizard.

This setup wizard have 5 steps to complete :
      Step 1 :  Welcome Screen

Setup wizard 1

     This step is a 'welcome message'.

      Step 2 :  Project Type

Setup wizard 2

      In this window we have to select the setup project type. Here we have four options:

Do you want to create a setup program to install an application:

    Create a setup for a Windows application
    Create a setup for a web application

Do you want to create a redistributable package:

    Create a merge module for Windows Installer
    Create a downloadable CAB file

Here we will use the 'Create a setup for a Windows application', as our project is a C# project Windows application.

      Step 3 : Project Outputs

Setup wizard 3

Here we have to select the project outputs we want to include in our installation package. For this project I select 'Localized resouces from Project', 'Content file from project', 'Primary output' which includes in the application DLL or EXE.
      Step 4 : Aditional file to include

Setup wizard 4        
      Here we have an option to include aditional files into our setup.

      Step 5 : Final Confirmation

Setup wizard 5

     Here you can see all the setting what you choose in previous steps to confirm. From this step you can easily go back and change the settings.

Step 6 : Finish
     If the project was successfully created, we will see the below window.

Setup Finish

Now you can set the different properties of the setup project from property window.


No responses found for this thread. Be the first to respond this thread.
Post Reply
Login to post Response.