Pages

Friday 22 June 2012

MSI Shortcut Table



Shortcut table holds the information the application needs, to create shortcuts on the user's computer. Shortcut table has the following columns:





Shortcut:
This column contains the name of the shortcut.

Directory:
This column specifies the directory in which the Shortcut file is created.

Name:
The localizable name of the shortcut to be created

Component:
 This column references to the name of the component that contains the shortcut.

Target:
The value in this column varies for advertised and non-advertised shortcuts. For advertised shortcuts the value in this column references to the Feature which contains the component that owns the shortcut. And in the case of non-advertised shortcuts the value in this column will be formatted string, and this particular formatted string will a folder or file containing the shortcut. To convert the non-advertised shortcuts into advertised shortcut resolve the formatted string to its full path.

 Arguments:
This particular column references to the command-line arguments for the shortcut.

Description:
This column refers to the description of the shortcut.

Hotkey:
Authors of installation packages are generally recommended not to set this option, because the setting of this option can add duplicate hotkeys to a user's desktop.

Icon:
This is a foreign key to the Icon table. If this is null, the icon in the target file is used.

IconIndex:
This must be a non negative integer.

ShowCmd:
The Show command for the application window.

Value
Style
1
SW_SHOWNORMAL
3
SW_SHOWMAXIMIZED
7
SW_SHOWMINNOACTIVE

WKDir: This column contains the working directory of the shortcut.




Directory table contains all the directories in an msi file. A directory can have a parent and child directories. If the parent or child directory of any directory is to be modified it can be done through this table. This table also lists all the parent directories of each directory. The Directory table has the following columns:




Directory:
Directory column contains a unique identifier for a directory.

Directory_Parent:
Directory_Parent column is a reference to the directory's parent directory. Directory that has a Directory_Parent column equal to null or equal to the Directory column represents a root directory.

DefaultDir:
This column references to the name of both the target and source directories.


MSI FeatureComponents Table



FeatureComponents table defines the relationship between all the features and components of an msi file. If we have to change the feature of any component it can also be done through this table. For each feature, this table lists all the components that make up that feature. The following are the columns of FeatureComponents table:



 Feature_:
An external key into the first column of the Feature table.

Component_:
An external key into the first column of the Component table


MSI Feature Table



Feature table explains the logical tree structure of features. There should be atleast one feature in every MSI file. And a feature can have a parent and child features also. Feature table contains the list of features that are present in a specific MSI file. The following are the columns of Feature table:

For example suppose there are two features Feature 1 and Feature 2 in a specific msi file.  Suppose ‘Feature 1’ feature is child feature of ‘Feature 2’ feature.

Let us discuss about the feature ‘Feature 1’.
Feature Column:
 It is a Primary key used to identify a particular feature record. Feature column shows Feature 1 as primary key for feature Feature1.

Feature_Parent:
Feature 2 will be its parent feature, since Feature 1 feature is a child feature of Feature 2.

Title:
Title will be the Short string of text identifying the feature. So in this case it will be Feature 1.

Description:
Longer string of text describing the feature. It can be NULL

Display:
     
Value
Appearance in UserInterface
NULL
Feature not displayed
ODD NUMBER
Displayed as expanded
EVEN NUMBER
Displayed as collapsed


Level:
The initial installation level of this feature. An install level of zero disables the item and prevents it from being displayed.

Directory:
Directory_ column specifies the name of a directory that can be configured. In this particular example the Directory is INSTALLDIR.
Directory
Full path
1) INSTALLDIR
C:\ProgramFiles\{Application Name}.
Ex: “C:\Program Files\Adobe”. Where Adobe is application name.
2) TargetDir
Ex: “C:\”


Attributes:
This field specifies the remote execution option for features that have not yet been installed and for which no feature state request has been made using any of the properties. If this field is blank, the value defaults to 0. 

First Time Self Healing


If the package is containing some HKCU entries then the package will always go for self healing for the first time. This happens because the HKCU keys are only installed for the current user present while installing the package and not all the users as it is the property of the HKCU. So, if other user logs
in then there is a mismatch between the current system state and the value specified in the MSI package (e.g., a key file is missing), then the related feature is re-installed. This is called the Self Healing.

ARP related Properties in MSI

Add/Remove Programs related MSI Properties





Property name
Brief description of property
ARPAUTHORIZEDCDFPREFIX
URL of the update channel for the application. The value the installer writes under the Uninstall Registry Key.
ARPCOMMENTS
Provides Comments for the Add/Remove Programs in the Control Panel. The value the installer writes under the Uninstall Registry Key.
ARPCONTACT
Provides the Contact for Add/Remove Programs in the Control Panel. The value the installer writes under the Uninstall Registry Key.
ARPINSTALLLOCATION
Fully qualified path to the application's primary folder. The value the installer writes under the Uninstall Registry Key.
ARPHELPLINK
Internet address, or URL, for technical support. The value the installer writes under the Uninstall Registry Key.
ARPHELPTELEPHONE
Technical support phone numbers. The value the installer writes under the Uninstall Registry Key.
ARPNOMODIFY
Prevents display of a Change button for the product in Add/Remove Programs in the Control Panel.
Note   This only affects the display in the ARP. The Windows Installer is still capable of repairing, installing-on-demand, and uninstalling applications through a command line or the programming interface.
Windows NT 4.0 and Windows 98/95:  Clicking on Add/Remove for the product uninstalls the product after prompting the user to confirm the uninstallation.
ARPNOREMOVE
Prevents display of a Remove button for the product in the Add/Remove Programs in the Control Panel. The product can still be removed by selecting the Change button if the installation package has been authored with a user interface that provides product removal as an option.
Note   This only affects the display in the ARP. The Windows Installer is still capable of repairing, installing-on-demand, and uninstalling applications through a command line or the programming interface.
Windows NT 4.0 and Windows 98/95:   This property prevents display of the application in the Programs List of the Add/Remove Programs in the Control Panel.
ARPNOREPAIR
Disables the Repair button in the Add/Remove Programs in the Control Panel.
Note   This only affects the display in the ARP. The Windows Installer is still capable of repairing, installing-on-demand, and uninstalling applications through a command line or the programming interface.
ARPPRODUCTICON
Identifies the icon displayed in Add/Remove Programs. If this property is not defined, Add/Remove Programs specifies the display icon.
ARPREADME
Provides the ReadMe for Add/Remove Programs in Control Panel. The value the installer writes under the Uninstall Registry Key.
ARPSIZE
Estimated size of the application in kilobytes.
ARPSYSTEMCOMPONENT
Prevents display of the application in the Programs List of the Add/Remove Programs in the Control Panel.
Note   This only affects the display in the ARP. The Windows Installer is still capable of repairing, installing-on-demand, and uninstalling applications through a command line or the programming interface.
Windows NT 4.0 and Windows 98/95:  This property has no effect.
ARPURLINFOABOUT
URL for application's home page. The value the installer writes under the Uninstall Registry Key.
ARPURLUPDATEINFO
URL for application updates information. The value the installer writes under the Uninstall Registry Key.

How to hide Drives in My Computer?


Create registry as described below:


HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer
Name: NoDrives
Data Type: REG_DWORD
Value: varies - see below
  
To calculate the value to use, add up the following codes for the drives that you want to hide:
A=1
B=2
C=4
D=8
E=16
F=32   
For instance to hide the E and F drives, the value would be 48