Previously, in Pt. I of this series, I wrote about how to install HKCU registry keys (which can also be used for installing data anywhere in a user profile). Now I’ll go into more depth on how to do this using the popular application packaging product Wise Package Studio.
Though Wise Package Studio has been discontinued by Symantec, it’s still quite popular in many packaging environments. The main tool used for creating and editing Windows Installer projects in Wise Package Studio is the “Windows Installer Editor”, which was previously available alone as “Wise for Windows Installer” (wfwi.exe).
Most of the packaging work will be done in the “Installation Expert” view, which is a slightly more “user friendly” or “cleaner” project editor. After creating my new project, I’ll add a couple files to it. The files I added are Process Explorer (procexp.exe) from “SysInternals” and it’s help file (procexp.chm). Process Explorer is one of several extremely useful utilities available (free!) in the Sysinternals Suite.
Next, I’ll add an “Advertised” desktop shortcut to “procexp.exe” from the “Shortcuts” page. By default, when you add a shortcut to point to a file in your installation the “Advertised” check box is marked.
Note that “Complete” is listed in the “Current Feature” drop down list. By default, Wise starts with a feature named “Complete” and puts all files, registry keys, shortcuts, etc. under the “Complete” feature, but we need a “hidden” parent feature. So, from the Features page “Add” a new feature. Give it a name, select “<None>” from the Parent drop down list, “Hidden” from the Display drop down, and check the “Required Feature” check box; the rest of the defaults can be left. After adding the hidden parent feature, I go into the “Complete” feature to select the hidden feature from its “Parent” drop down list.
Finally, I add an HKCU registry key to the new hidden feature. Notice now that I’ve added a new feature, I can select it from the “Current Feature” drop down list from all the pages in Installation Expert.
After the project is compiled, the .MSI can be run on any system “per machine” with the “ALLUSERS” value set to ‘1’. When a new user logs onto the machine and clicks on the advertised shortcut, the HKCU key will be installed by the windows installer repair.
Next time, I’ll take a look at implementing self repair using InstallShield. I hope you found this tutorial enlightening, instructive, and maybe even a little fun. Well..uh..instructive and enlightening should be good enough!