This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
from… (Or any other files which you want to create shortcut for them), select create shortcut
to… then the shortcut will appear, cut it and paste to the folder where you want a shortcut to
appear. Also you can add project outputs in the target folder using the same way explained below
just select project output... instead of a file.
User interface editor;
The user interface editor helps you to customize the installation wizard interface.
The User Interface Editor is a tree control containing two sections: Install and Admin. The Install section contains dialog boxes that will be displayed when the end user runs the installer; the Admin section contains dialog boxes that will be displayed when a system administrator uploads the installer to a
network location. You may change the statements that appear during installation categorized in the three predefined dialog boxes (Start, progress & end).
Registry editor;
The Registry Editor allows you to specify registry keys and values to be added to the registry of the target computer. By default the Registry Editor displays a standard set of registry keys that correspond with the standard Windows registry keys: HKEY_CLASSES_ROOT, HKEY_CURRENT_USER, HKEY_LOCAL_MACHINE, HKEY_USERS, and HKEY_PER_USER. For Setup projects, additional keys that match the Manufacturer property for the project are displayed under HKEY_CURRENT_USER\Software and HKEY_LOCAL_MACHINE\Software.
Playing with registry need more experienced person otherwise it may course some trouble in target computer, but you can add or remove keys according to what your project needs.
To add a registry key select a top level node, in the action menu click new key, then type the new name and edit properties of the key in the properties window as necessary.
To add a sub key select a key node, in the action menu point to new and then key and you can edit its properties from the properties window. Also you can remove a key by selecting it and then click Delete from Edit menu. Also you can add string, binary, and DWORD values. During installation the values will be written to the registry and any existing values will be overwritten by the values that you specify.
Custom actions editor;
Here you can specify additional actions to be performed on the target computer at the end of an installation.
Five predefined custom actions are included in Visual Studio to install Event Log, Message Queue, Performance Counter, Service, and Service Process components. When these components are configured as installation components, they are wrapped in an installer class and are recognized by the deployment system as a custom action.
The editor contains four folders, each corresponding with a phase of installation: Install Commit, Rollback, and Uninstall which are run in the same order that they are displayed in the editor.
To add custom actions first must be compiled as a .dll, .exe file or .NET framework component and added to a project as a script or assembly before they can be added to a deployment project. Then right click on one of the four folders and chose Add custom action then select your item to be added. If the item hasn't previously been added to the deployment project, click the Add File, Add Output, or Add Assembly button to add the item as a custom action. This also adds the item to your project. To add a
custom action to all four folders, select the Custom Actions node in the editor, and choose Add Custom Action.
File Types editor;
File Types editor allows you to specify document types and associate them with file extensions. In addition, you can specify the verbs or actions for each document type and specify MIME types for the document types for use in browsers.
The File Types Editor contains a single pane with hierarchical list of file types and actions. By default, the File Types Editor contains a single File Types on Target Machine node; new file types may be added beneath that node. There are three steps involved in associating a file type with your application: adding a document type, associating a file extension, and associating an executable file.
To add a document type, right click on File Type on Target Machine and select Add File Type and give it a name. Then you can associate it with file extension by going to its properties and type the extension without precede it by a period (separate multiple extensions by ;). Then you can set a command by selecting a .exe file associated with.
Launch conditions editor;
The Launch Conditions Editor allows you to specify conditions that must be met in order to successfully run an installation. For example you may check for the OS version, windows installer components, registry key or even a file if it exists in a target machine.
To add an item to search right click on Search Target Machine and then select an item you want to be searched in the target machine and then set its properties from the properties window. The following pictures from MSDN summaries the properties available:
To make your application run in any version of .NET framework, right click on Requirement on Target Machine and then click Add .NET Framework Launch Condition, in properties window change Version to Any. There are editors available in setup project in visual studio.
Choosing prerequisites to install:
Sometimes your application may depend on components that must be available in target computer before the installation can take place. If one of those dependent components is not available, an error message will be raised and installation will be aborted!
You can make your user fill happy without a list of error messages, by including some prerequisites to be installed if not available in target computer.
To choose which one to be included in your package, right click on your deployment project and select properties, in the Property Pages dialog box, expand the Configuration Properties node, and then select the
Build property page. Click the prerequisite button and make sure that the Create setup program to install
prerequisite components box is checked. Then select the prerequisites that you want to install from the
Here you can select example the .NET framework version and windows installer version and other prerequisites
from the dialog box.
Down the dialog there is specify the install location for prerequisite, and three radio buttons are available:
This capability to automatically detect the existence of components during installation and install a
predetermined set of prerequisites is referred to as bootstrapping and the component that performs it is
called the generic bootstrapper which uses bootstrapper packages to install the prerequisite components on
the target computer.
The default location of the bootstrapper packages is stored in the registry key HKEY_LOCAL_MACHINE\Software\Microsoft\GenericBootstrapper\4.0\Path. Changing this path will change the location in which the Prerequisites Dialog Box looks for bootstrapper packages.
Creating installer for 64 bit platform:
The deployment tools in Visual Studio allow you to create installers for 64-bit applications and components. The TargetPlatform Property of a deployment project determines whether an installer will target a 32-bit or a specific 64-bit platform. The target platforms are x86 for 32-bit platforms, x64 for computers supporting the AMD64 and EM64T instruction sets, and Itanium for the 64-bit Itanium processor.
In general, 32- and 64-bit Microsoft Installer (MSI) packages are treated in the same way except for how Windows Installer treats folder variables such as Program Files and System Folder, and how it writes components into the registry or GAC. To create a 64 bit installer select your setup project and in the properties window change TargetPlatform to either Itanium for an Intel Itanium 64-bit platform, or x64 for
any other 64-bit platform (such as AMD64 and EM64T instruction sets).
Windows Installer can use digital signatures to detect and correct corrupted resources. In Windows XP, Windows Installer is integrated with Software Restriction Policy to restrict both administrators and non-administrators from running program files based on the path, URL zone, hash, or publisher criteria.
Also you can sign an assembly which gives an application a unique identity that other software can use to identify and refer explicitly to it (process also called strong-name signing). A strong name consists of its simple text name, version number, culture information (if provided), plus a public/private key pair. This information is stored in a key file; this can be a Personal Information Exchange (PFX) file or a certificate from the current user's Windows certificate store.
To sign an assembly, right click on project and click properties, from the project form click the signing tab and then select the sign the assembly. From a Choose a strong name key file drop-down list, select either <new…> if you want a new key file or <browse…> for an existing file. For new file enter a name and password in the Create strong Name key.
Now rebuild your application and then a setup project to get a .msi file ready for installation.
2. ClickOnce technology:
To make a ClickOnce application available to users, you must publish it to a Web server, file share, or
removable media. You can publish the application by using the Publish Wizard; additional properties
related to publishing are available on the Publish page of the Project Designer.
Publish properties can be set using the Publish Wizard but only a few of the properties are available in it,
all other properties are set to their default values. Now let’s look at the properties that can be changed
in this Publish page:
Publish location;
You can publish the application to a Web site, FTP server, or file path. Type the location as a disk path,
file share, FTP site, or Web site URL, or click the Browse button to browse for the location.
Disk path: Specify a local disk path from which you can copy the application to a CD-ROM or DVD-ROM. The path can be a relative or absolute path in standard Windows format, for example: C:\Deploy\DIC.
File share: Specify a file share by using a Universal Naming Convention (UNC) path from which the application will be deployed, for example: \\ServerName\DIC\.
FTP server: Specify the path of a Web site from which the application can be downloaded by using FTP, for example: ftp://ftp.fileServer.com/DIC.
Web site: Specify the URL of a Web site from which the application can be downloaded by using HTTP, for example: http://www.website.com/DIC.
Install mode and settings;
First you have to say if the application is available offline or not (online only). If you select The
application is available online only, then it will be run directly from the publish location without
creating a shortcut on the start menu. Otherwise the application will be available even if a user is
disconnected from the network and a shortcut will be available on start menu.
Also you can click on Prerequisites.. button to specify which prerequisite to be included. The
prerequisite dialog is the same as the one explained above in windows installer.
Father more, if you set your application to be available offline, you can set application updates either
automatically or programmatically. Also you can configure the application to check for updates
automatically before the application starts, or at set intervals after the application starts. In addition you
can specify a minimum required version; that is, an update is installed if the user's version is lower than
the required version.
Publish version;
To increase publish version, increase major, minor, build or revision version number according to what
updates you have made! Changing the number in these fields causes the application to be published as
an update. Also you can clear the Automatically increment revision with each publish if you don’t want
visual studio to automatically increment the clickOnce publish version.
Then click on Publish Now to publish your application after making sure that all settings of your
application have already been set correctly.
Security in ClickOnce:
ClickOnce security relies on Authenticode certificates to determine whether an application should be installed, a step known as a trust decision. Application and deployment manifests that describe an application can be signed with a certificate to prevent tampering. Domain administrators can configure certificates to be trusted at the enterprise or machine level. If certificates are not trusted at the time of installation, ClickOnce deployment can be configured to ask users to make trust decisions. Once an application is installed, ClickOnce restricts the application permissions and actions as defined by the Internet, Local Intranet, or custom zones.
3. InstallShield 2010 Limited Edition:
Microsoft has partnered with Flexera, makers of InstallShield to create InstallShield LE for Visual Studio
2010. This is a Visual Studio extension you can download and use today to build Windows installer-
based deployment packages for your application that can be deployed on the Windows platform. It
provides comparable functionality to the Visual Studio Installer project but in addition, you get the easy
to use, modern, graphical development environment of InstallShield, as well as the ability to build your
deployment projects using Team Foundation Server.
First time users need to enable InstallShield LE by downloading and installing it. Go to create new project
and select InstallShield. After creating the project the template will bring you to registration page and then
the download link. Once you have installed the product, the new project dialog will provide an option to
create an installShield LE project. Now after creating a new project, the first form is where we start now: