Jump to content

Install App Based on Hostname


Recommended Posts

I have a text file with about 150 PC Hostnames included:

PC1

PC2

PC3 etc...

I need to run an installation for each machine that is listed in this file....The install is located on a network share \\NETSHARE\SETUP.EXE

It needs to run with an -S argument (i.e. \\netshare\setup.exe -s)

How do I write an AutoIT script to do this....?

Alternatively, how do I write a script that runs the install IF the PC has either Office 2000 OR Office 2003 professional installed...

Thanks,

-Jones

Link to comment
Share on other sites

How do I write an AutoIT script to do this....?

Alternatively, how do I write a script that runs the install IF the PC has either Office 2000  OR  Office 2003 professional installed...

<{POST_SNAPBACK}>

Something like:

if fileexists("C:\program files\microsoft office\office 11\winword.exe")... ?

I believe Office 2K would be under an "Office 10" directory. Check your target systems for confirmation.

Hope that helps.

Link to comment
Share on other sites

Thanks Xander....

I used:

If FileExists("C:\Program Files\Microsoft Office\OFFICE11\Outlook.exe") Then
    Run("\\hnmsrvlds001\ldlogon\zix2003\setup.exe -s")

ElseIf FileExists("C:\program Files\Microsoft Office\office\Outlook.exe") Then
    Run("\\hnmsrvlds001\ldlogon\zix2000\setup.exe -s")

EndIf

Works perfectly.

-Jones

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...