View Full Version : Change all component code (GUIDs) in .ISM using Windows Installer API?

12-19-2003, 07:01 AM
We are moving from V7 to V8 of our product. V8 will be a new product, with a new Product Code, but it will be largely identical to V7 in terms of components/files.

Rather than manually taking our existing V7 .ISM file and customising it (we have about 120 components), I'd like to use the Windows Installer API to programmatically change the V7 .ISM file to provide a starting point for V8.

By this I mean, open the .ISM and:

* Re-generate new component codes (GUIDs) for all components

* Change records in tables where the the component code is a foreign key to the new component code value (for example, the File table has a foreign key pointing back at the Component table, so any change of component code would need the foreign keys to be changed also)

* Change entries in the file table which have filenames with a particular version-specific filename (i.e. AppFile70.EXE -> AppFile80.exe).

I'm experienced with the API, and at changing MSI/ISM files programmatically, but not on such as scale.

Has anybody done anything like this before, or can anybody recommend a good resource for planning how to do it?



01-06-2004, 03:47 PM
Just a comment on using APIs on the ISM ... I have heard that some APIs don't work on the ISM file like they would on a true MSI file (eventhough the format of the SIM is patterened after the MSI)