Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Issue with MSP(Updating Component Destination)


1 reply to this topic

snip

snip
  • Full Members
  • 4 posts

Posted 11 April 2011 - 10:27

Hello,

I am trying to get a patch(using Installshield's Patch Design View) where i have changed the destination location(folder) of a component in my updated MSI. When i "Build Patch" i get an errror saying that the component is removed in updated MSI and "RemoveFile" table should be authored. Despite of the error , i get a patch (.msp file) and i can install it. Once i install this patch the component is never installed on target system even though the logfile says that the Component is marked to be installed "Locally".

Some update on my MSI's (Created them for the test): -
1) My base MSI has a single Feature with single component. I chose [WindowsFolder] to be its destinnation. This component has a text file marked as key file for the component.
2) My updated MSI changed the component destination folder to [INSTALLDIR], rest all remains same(Component Name, Component GUID)

My question is why am getting an error that component is removed in updated MSI even though the component is present in updated MSI. Can we not change the destination folder for a component while patching, how WI is treating this change?

Also if this is an error in Installshield (coming with X mark in red color) , why the build of the patch not stopping and why am i getting a msp file out of it? Is this some bug in Installshield.

NOTE: I am using Installshield 2011 professional. Also find attached the logfile for it.

Attached Files



MSIYER

MSIYER
  • Full Members
  • 90 posts

Posted 11 April 2011 - 12:56

Each component should have a key file. The key file's name and the complete path are used in combination by the Windows Installer for various purposes.Thus, key files are also called key path.

Do not change the path of the key file when you are creating a patch. When you change the key path you effectively alter the key file + key path combination and the installer engine considers the component as a new one. This violates the basic rule:
That no component can be removed from the feature tree in a minor upgrade.

Remember, it is the combination of file name and its path that forms the key file or key path.

Having the same component GUID will not help you in this case. The GUID value is used by the installer engine to create a key(with the GUID as name) in the registry where it stores the key file + key path. The GUID also distinguishes Component A from Component B.

Also, logically when you install a component to, say path A, you have to patch it at path A itself. Patching is not a complete uninstall and re-install business. Its just patching. You are shipping the delta of old msi and the new msi to users.

For an analogy:
You stitch or patch your trouser where it is torn.

Go through this:
http://msdn.microsof...7(v=vs.85).aspx

Regarding Error messages:
The error messages are actually pointers and not complete description of the problem. This is true with any tool. At times the messages are apt and at times you need to dig into the matter, as you are now.

Hope this helps.

Edited by MSIYER, 11 April 2011 - 13:17.