Planning a Major Upgrade

If Windows Installer is used for the installation and setup of an application, later upgrades of that application can be handled by installing an upgrade package. Setup developers may choose to author an upgrade package by modifying the original installation package. This approach is illustrated by the following upgrade example.

The installation of the original product, MNP2000, followed by the installation of the upgrade package provides the user with the following files required by the product MNP2001.

FileDescriptionPath to sourcePath to target
Redpark.exeText editor executable file. Unchanged from previous products.C:\Sample\Notepad\Redpark.exe[ProgramFilesFolder]\Red_Park\Redpark.exe
Readme.txtAn information file. Unchanged from previous products.C:\Sample\Notepad\Readme.txt[ProgramFilesFolder]\Red_Park\Readme.txt
Help.txtHelp manual. Unchanged from previous products.C:\Sample\Notepad\Help.txtNot installed. Always run-from-source.
Baseba01.txtBaseball game schedule for year 2001.C:\Sample\Notepad\Events\Baseba01.txt[ProgramFilesFolder]\Red_Park\Sports\Baseball.txt
Footba01.txtFootball game schedule for year 2001.C:\Sample\Notepad\Events\Footba01.txt[ProgramFilesFolder]\Red_Park\Sports\Football.txt
Basket01.txtBasketball game schedule for year 2001.C:\Sample\Notepad\Events\Basket01.txt[ProgramFilesFolder]\Red_Park\Sports\Basket01.txt
Dance01.txtDance performances for year 2001.C:\Sample\Notepad\Events\Dance01.txt[ProgramFilesFolder]\Red_Park\Arts\Dance.txt
Concert01.txtMusic performances for year 2001.C:\Sample\Notepad\Events\Concer01.txt[ProgramFilesFolder]\Red_Park\Arts\Concert.txt
Opera01.txtOpera performances for year 2001.C:\Sample\Notepad\Events\Opera01.txt[ProgramFilesFolder]\Red_Park\Arts\Opera01.txt
Januar01.txtAdmissions in January of year 2001.C:\Sample\Notepad\Gate\Januar01.txt[ProgramFilesFolder]\Red_Park\Gate\January.txt
NewYea01.txtAdmissions on New Years Day of year 2001.C:\Sample\Notepad\Gate\Holidays\NewYea01.txt[ProgramFilesFolder]\Red_Park\Gate\NewYears.txt
Memori01.txtAdmissions on Memorial Day of year 2001.C:\Sample\Notepad\Gate\Holidays\Memori01.txt[ProgramFilesFolder]\Red_Park\Gate\Memori01.txt

 

Installation of the upgrade package removes all the features installed with the original product that are not being used by the upgraded product.

For example, when upgrading from MNP2000, installation of the upgrade removes the following files from the user's computer:

  • Baseball.txt
  • Football.txt
  • Dance.txt
  • Concert.txt
  • January.txt
  • NewYears.txt

Installation of the upgrade package writes the following values in the user's registry under:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Notepad Sample

NameValue
lfCharSet0
lfClipPrecision2
lfFaceNameFixedSys
lfItalic0
lfOrientation0
lfOutPrecision1
fSavePageSetting0
lfPitchAndFamily49
iPointSize120
lfQuality2
lfStrikeOut0
lfWeight400
fWrap0

 

The upgrade updates old shortcuts to the following shortcuts. One of these shortcuts may be selected during setup as an advertised shortcut so that the user can install-on-demand the Baseball feature.

NameShortcut locationShortcut target
sNotepad[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Redpark.exe
sReadme[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Readme.txt
sHelp[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Sample\Notepad\Help.txt
sBaseball[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Sports\Baseba01.txt
sFootball[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Sports\Footba01.txt
sBasketball[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Sports\Basketba01.txt
sDance[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Arts\Dance01.txt
sConcert[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Arts\Concer01.txt
sOpera[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Arts\Opera01.txt
sJanuary[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Gate\Januar01.txt
sNewYears[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Gate\NewYea01.txt
sMemorial[ProgramFilesFolder]\Red_Park\Menu\[ProgramFilesFolder]\Red_Park\Gate\Memori01.txt

 

When a user uninstalls the upgrade package, Windows Installer completely removes all versions of the product from the user's computer. The user is not left with any parts of MNP2000 or MNP2001.

Continue

 

 

Send comments about this topic to Microsoft

Build date: 2/4/2010

Tags :


Page view tracker