Hi,

I want to be able to complete an install such that the InstallLocation property 
of the Win32_Product WMI class is properly filled in. Here is an example script 
for enumerating Win32_Product instances and their properties:

----------------------- cut products.js ------------------------------------
var objOMIServices = GetObject("WinMgmts:Root\\CIMV2");
var objWMIInstances = objOMIServices.InstancesOf("Win32_Product");

var processInstances;
var process;
var processProperties;
var property;

processInstances = new Enumerator(objWMIInstances);
for (; !processInstances.atEnd(); processInstances.moveNext())
{
   WScript.Echo(" ");
   process = processInstances.item();
   processProperties = process.Properties_;
   propertyEnumerator = new Enumerator(processProperties);
   for (; !propertyEnumerator.atEnd(); propertyEnumerator.moveNext())
   {
      property = propertyEnumerator.item();
         WScript.Echo(property.Name + " " + property.Value);
   }
}
------------------- cut products.js -----------------------------------------

When I run this script I see very few products have anything in 
InstallLocation. Does anyone know how to do this using WiX.... Or even the SDK 
alone?

(note: if you run this on Windows Server 2003 and don't see anything, its 
likely because you need to go to Control Panel->Add or Remove 
Programs->Add/Remove Windows Components->Management and Monitoring 
Tools->Details->WMI Windows Installer Provider)



-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to