So, I am not having any luck retrieving any info from the WindowsInstaller::Installer object in KIX.
The following VBscript code lists the MSI product IDs for all products installed on this system:
code:
Dim installer, Products
Set installer = Nothing
Set installer = Wscript.CreateObject("WindowsInstaller.Installer")
Set Products = installer.Products
For Each product In Products
Wscript.Echo product
Next
Set Products = Nothing
Set installer = Nothing
That works fine. The same code in KIX, however, does not list anything:
code:
$installer = CreateObject("WindowsInstaller.Installer")
$Products = $installer.Products
For Each $product In $Products
? $product
Next
Other COM code such as the WMI example in the KIX 4.02 doc ($Drives = GetObject("winmgmts:").ExecQuery("select Name,DriveType from Win32_LogicalDisk")
) does work.
I must be missing something very simple.
Any help would be greatly appreciated - I don't want to have to use two different languages for a single task.
Also, can someone clarify the difference between GetObject() and CreateObject()?
TIA