C # VS program packaging,

Source: Internet
Author: User

C # VS program packaging,

VS2012 does not have its own packaging tool. Therefore, you must first download and install a packaging tool. I use the packaging tool InstallShield2015LimitedEdition provided by Microsoft. : Http://pan.baidu.com/s/1c229wdu,password: nbnd. Note: After the packaging tool is installed, use the registration code to activate it before packaging. If you choose to try it out, you will be prompted when installing the packaged software. The approximate content is: this software is packaged using unregistered tools. (PS: the user experience is mostly affected. If you haven't installed or used it, you will receive a warning)

  Detailed packaging process: 1. Create an installation and deployment project

In Solution Explorer of the project to be packaged, right-click solution *** and add new project. In the pop-up box, select and set the following information:

The structure of the created resource manager is as follows:

2. Set Basic Program Information

Application Information mainly sets Information about programs displayed during installation, including program development companies, program names, program version numbers, and the company's official website.

You can also set more detailed Information for General Information:

3. Set installation requirements

Installation Requirements focuses on selecting supported operating systems and other dependent software frameworks. Select as needed.

4. Add an application file

Application Files is used to set the Files contained in the Application lock. The DLL referenced by the program, other files, such as exe files and chm files, are added in this step.

First, set the main output of the program (the main output is the main body of the program, including the start and entry of the program ):

Procedure: 1. select the program name (red box on the left); 2. click "Add Project Outputs" 3. select primary output (red box on the left). 4. click "OK"

Use "Add Files" to Add DLL Files and other Files referenced by the program.

5. Set the program shortcut icon

 

Procedure:

 

1. Click "Create an uninstallation uninstall cut" on the left to Create an uninstall project for the program;

 

2. click "New... ", select the" *. main output file. The default name is "Built". You can use the "rename" button to change the name. This name will be displayed under the installer icon (such as the QQ icon on the desktop ); you can also set program export cut to select the icon displayed on the desktop or Start Menu after the program is installed;

 

3. Set the display position of the program icon and unmount option icon, such as the four boxes.

6. Set the registry information of the program.

Or skip this step.

7. Set the installation View

Set as needed.

8. Publish a program

The above installation steps are completed to generate a solution, but the generated file will be placed in the DVD-5 folder, to use the installation file, you must copy the entire folder or else the installation will be wrong, this content is cumbersome and provides a poor installation experience.

Solution: Use the singleimageinstallation package to integrate all the files into a setup.exe. only one setup.exe will be available for the next installation.

Step: Right-click the "solution" attribute and then click set.

9. Package the installation environment together

The procedure is as follows:

After the preceding steps, the program is packaged and the packaged exe file is:

During the packaging process, you may encounter various errors. You can search for them based on the error code and solve them one by one. Then, the packaged program can be installed and executed.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.