Is there any way to extract the product code from a patch? I try to use
the installer interface with the method SummaryInformation but i always got
empty property. I know that the msp file have this information, i do open
the msp file with OLE strutured storage and i see this information inside
the patch.
Any one have any idees ?
Thanks.
Eric
--
Re~Silient
WPO11
WinXP SP1 Home
"Eric Lacroix" <elac...@cch.ca> wrote in message
news:OfjxdHhG...@TK2MSFTNGP10.phx.gbl...
"Re~Silient" <resi...@videotron.ca> wrote in message
news:#paQpdkG...@TK2MSFTNGP10.phx.gbl...
Openning an installer database does not give any good result because
information about the patch are not stored inside table.
Just try to drag an msp file over orca and you will see what in it.
thanks,
eric
"Luke S" <sur...@ca.com> wrote in message
news:ueBm%23jmGD...@TK2MSFTNGP10.phx.gbl...
=========================
Set Installer = WScript.CreateObject("WindowsInstaller.Installer")
Set SummaryInfo = Installer.SummaryInformation("d:\patches\simple\msps\simple.msp", 0)
' List of target products in the patch is stored in the Template property of the Summary Information
stream
' Target products could be a multiple delimited list (by ';')
' TODO: process the returned value as a list
strTargetProductList = SummaryInfo.Property(7)
MsgBox "Patch Target Product List = " & strTargetProductList
' Revision property of summary information stream contains the PatchCode followed by the GUIDs of
' patches to obsolete (no delimiter)
' TODO: process the returned value as a possible list
strPatchCode = SummaryInfo.Property(9)
MsgBox "Patch Code = " & strPatchCode
=========================
Also, Luke is correct as far as the MSI API functions go. The patch information related to target
products for the patch is stored in the Template property of the summary information stream. You
could either use MsiGetSummaryInformation with the handle to the database (i.e. patch) obtained with
the MsiOpenDatabase call that also specified MSIDBOPEN_PATCHFILE. Alternatively you could simply
call MsiGetSummaryInformation with the patch to the patch.
--
- Carolyn Napier
Microsoft Windows Installer Team
Check out the Windows Installer FAQ at:
<http://www.microsoft.com/windows2000/community/centers/management/msi_faq.asp>
Please do not send email directly to the alias used to post to the newsgroup. The alias is for
newsgroup purposes only. This posting is provided "AS IS" with no warranties, and confers no
rights. Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
"Eric Lacroix" <elac...@cch.ca> wrote in message news:OHhQDv7G...@tk2msftngp13.phx.gbl...