Script Center > Scripting Forums > The Official Scripting Guys Forum! > Looking for help need s script I can run to go out on network and discover and tell me the Machine names of PCs that have Office 2007 installed on them
Ask a questionAsk a question
 

QuestionLooking for help need s script I can run to go out on network and discover and tell me the Machine names of PCs that have Office 2007 installed on them

  • Wednesday, July 01, 2009 5:57 AMdanstanl Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    My company recently is rolling out Office 2007 to groups of PCs in our domain single domain that is , well the end of this migratio from Office xp to Office 2007  is coming soon but  I want to be able to run a script that will identify by Comuter name which PC's have the Office 2007 suite installed. Does any one have a script for this or now how I could start one I am relatively new to scripting I know some VB and basic bpatch scripting that is it.

    -d

All Replies

  • Thursday, July 02, 2009 8:10 AMAssafM Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Hi,

    You could use WMI Query for this.

    Write a script that loops on a list of computers.
    It will Connect to Each Computers WMI and Query for:

    " Select Name from Win32_Product Where Name Like 'Microsoft Office%2007' "

    This Query will give you only the Name of the Product installed and it will give you all the Products that Start with Microsoft Office and Ends with 2007.

    It is allways best to query WMI with a Specific Query.

    You can Use This Post For Guidence

    Then you have only to chek That the colItems (Like from the Post) Count is Greater than 0 
    And you can be Assured that Office is installed on that Computer.

    If you want Extra Checking you can Check the Name of Each Item in the Collection to see if it really is The Office Version You Need.

    Good Luck

    Assaf Miron http://Assaf.Miron.googlepages.com