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

Registry kook up of installed ComponentID?


5 replies to this topic

jameskoch

jameskoch
  • Full Members
  • 3 posts

Posted 03 July 2008 - 03:24

*LOOK UP* I meant LOOK up...

CODE
SELMGR: ComponentId '{36C1B951-D1AB-4567-AA62-9BD86C894FA7}' is registered to feature 'QBFC5', but is not present in the Component table.  Removal of components from a feature is not supported!


I'm noticing this error in my log, and thanks to the posts I've found on this board I have a decent understanding of why it's occuring.

My problem is that I've been unable to determine which file this ComponentID is referring to so that I can add it back to my project. It's not something I've been able to track down inside my own InstallShield 12 project (or any of its past versions), so my theory is that it's something from one of several merge modules I reference. I haven't had these merge modules under tight version control, and I think one may have changed on me. I've cracked open the latest versions of the suspect MSMs to look at the Components tables but I can't find anything that has this ID.

So I'm hoping someone can help me figure out how to look-up the state of this ComponentID on the target machine to at least get a hint at which file I'm dealing with. I've tried searching the registry for this GUID (with hyphens, without, and with underscores instead of hyphens) and have come up empty. Anyone have any hints (registry areas, MSI API calls, voodoo)?

James

Edited by jameskoch, 03 July 2008 - 03:30.


Zweitze

Zweitze
  • Full Members
  • 522 posts

Posted 03 July 2008 - 12:02

Load the old MSI (that is installed on that system) into Orca and use its Search function - it looks in all tables.

jameskoch

jameskoch
  • Full Members
  • 3 posts

Posted 03 July 2008 - 13:58

I'm not sure I have the MSI. But I think I've read something about an MSI cache, so I'll see if I can dig it up somewhere on the disk of the target machine. Any ideas, assuming I can't find it?

jameskoch

jameskoch
  • Full Members
  • 3 posts

Posted 03 July 2008 - 15:01

Found it. Thanks for the help. Great forum!

I'm still interest, out of pure curiosity, how this information could be obtained w/o the MSI, if anyone knows.

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 04 July 2008 - 09:57

As far as I know the GUIDs are stored in a "compressed" format to make it harder to find them and cause harm to the system by trying to modify the entries.

VBScab

VBScab
  • Full Members
  • 436 posts

Posted 04 July 2008 - 11:51

Indeed they *are* compressed but in such a brain-dead way that the motive simply cannot have been to stop users messing with them. A four year-old could work out the pattern.

Here are 2 functions, to convert GUIDs to and from what I call "munged" format.
CODE
'// There are several information types that Windows Installer writes into the registry, but for further
'// discussion it is important to distinguish between a standard and packed GUID (these and other
'// information types are discussed in various sources; a very good summary can be found, for instance,
'// in chapter 7 of "Administrator's Introduction to Application Repackaging and Software Deployment
'// using Windows Installer" by Bob Baker and Robert Dickau).
'//
'// To uncover some concealed internals of the installed .MSI package, one needs to correctly interpret
'// the content of the Packed ProductCode GUID key, which can be obtained from the Packed UpgradeCode GUID
'// registry key.
'//
'// A standard GUID requires 38 characters and contains 5 groups of hexadecimal characters separated by dashes.
'// The valid format for a standard GUID is:
'//  {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}
'//  where X is a hex digit (0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F).
'//
'// A packed GUID is an alternative representation that allows Windows Installer to reduce the space
'// in the registry database when storing a GUID. A packed GUID requires only 32 characters.
'// Its valid format is:
'//  XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
'//  where X is a hex digit.
'//
'// A packed GUID can be obtained by applying a transform to a standard GUID. This transform performs
'// the following operations:
'//  - removes the curly braces and separating dashes from a standard GUID;
'//  - writes the first three groups of hexadecimals characters in a standard GUID in reverse order;
'//  - switches every two characters in the fourth and fifth group in a standard GUID.
'//  - Someone coined the name Darwin Transform for this conversion procedure, since its primary use
'//    is to construct a well-known Darwin Descriptor, which is a combination of the product code GUID,
'//    a feature name, and a component code GUID.
'//
Function GetMungedProductCode(ByVal strProductCode)
 '// Visio 2002's Product code:
 '//  {90540409-6D54-11D4-BEE3-00C04F990354}
 '//    12345678901234567890123456789012345678
 '//               1         2         3
 '// Visio 2002's munged code:
 '//  9040450945D64D11EB3E000CF4993045
 '//    12345678901234567890123456789012345678
 '//               1         2         3

 Dim arrSequence
 Dim strMungedCode
 
 Const intArraySize = 32
 
 arrSequence = Array(9,8,7,6,5,4,3,2,14,13,12,11,19,18,17,16,22,21,24,23,27,26,29,28,31,30,33,32,35,34,37,36)

 '// Generate the RegProduct Code
 For intIndex = 0 To (intArraySize - 1)
  strMungedCode = strMungedCode & Mid(strProductCode, arrSequence(intIndex), 1)
 Next

 GetMungedProductCode = strMungedCode
End Function
 
Function ReconstructProductCode(ByVal strMungedCode)
 '// Visio 2002's Product code:
 '//  {90540409-6D54-11D4-BEE3-00C04F990354}
 '//    12345678901234567890123456789012345678
 '//               1         2         3
 '// Visio 2002's munged code:
 '//  9040450945D64D11EB3E000CF4993045
 '//    12345678901234567890123456789012345678
 '//               1         2         3
 Dim arrSequence
 Dim strProductCode
 
 Const intArraySize = 32
 
 strProductCode = "{"
 arrSequence = Array(8,7,6,5,4,3,2,1,12,11,10,9,16,15,14,13,18,17,20,19,22,21,24,23,26,25,28,27,30,29,32,31)

 '// Generate the Product Code
 For intIndex = 0 to intArraySize - 1
  strProductCode = strProductCode & Mid(strMungedCode,arrSequence(intIndex),1)
  If intIndex = 7 Or intIndex = 11 Or intIndex = 15 Or intIndex = 19 Then
   strProductCode = strProductCode & "-"
  End If
 Next
 
 strProductCode = strProductCode & "}"

 ReconstructProductCode = strProductCode
End Function

- Don't know why 'x' happened? Want to know why 'y' happened? ProcMon will tell you.
- Try using http://www.google.com before posting.
- I answer questions only via forums. Please appreciate the time I give here and don't send me personal emails.