+ Post New Thread
Results 1 to 4 of 4
Scripts Thread, Install software if computername contains "teacher" in Coding and Web Development; Ive got a few bits of software that need installing and tbh i thiink the best way is by a ...
  1. #1


    Join Date
    Oct 2006
    Posts
    3,412
    Thank Post
    184
    Thanked 356 Times in 285 Posts
    Rep Power
    149

    Install software if computername contains "teacher"

    Ive got a few bits of software that need installing and tbh i thiink the best way is by a script looking for "teacher" in the computername.

    Problem is im not sure how to do it. Guess VBS would be best. I know how to make it look for "x" in the last y charcters but not to simpley search the name.

    Any ideas?

    :beer:

  2. #2

    Geoff's Avatar
    Join Date
    Jun 2005
    Location
    Fylde, Lancs, UK.
    Posts
    11,804
    Thank Post
    110
    Thanked 583 Times in 504 Posts
    Blog Entries
    1
    Rep Power
    224

    Re: Install software if computername contains "teacher"

    Assuming your using AD and MSI's you can do this quite easily with a security filter on the GPO.

  3. #3

    Join Date
    Nov 2007
    Posts
    8
    Thank Post
    0
    Thanked 0 Times in 0 Posts
    Rep Power
    0

    Re: Install software if computername contains "teacher"

    It depends on the environment. If you are in Active Directory then I would either put all of your teacher's computers in a particular OU or put the teacher computers in a group and filter a group policy so that it only affects computers in that security group. Or as Geoff suggested using filters on your GPOs works just as well.

    If you have questions about how to do that, let me know and I can score you some links.

    If you need to grab the computer name here it is:
    Set WshNetwork = WScript.CreateObject("WScript.Network")
    WScript.Echo "Computer Name: " & WshNetwork.ComputerName

    Happy hunting and have a great day.

  4. #4

    plexer's Avatar
    Join Date
    Dec 2005
    Location
    Norfolk
    Posts
    13,679
    Thank Post
    661
    Thanked 1,626 Times in 1,455 Posts
    Rep Power
    422

    Re: Install software if computername contains "teacher"

    WMI filter?

    "SELECT * FROM Win32_ComputerSystem WHERE Name = '*teacher*'

    Not sure if the wild cards will work but it's a starting point for you.

    Ben

SHARE:
+ Post New Thread

Similar Threads

  1. Replies: 10
    Last Post: 30th August 2007, 10:52 AM
  2. Replies: 1
    Last Post: 15th June 2007, 04:16 AM
  3. Replies: 6
    Last Post: 28th September 2006, 07:06 PM
  4. Teacher "Buy-In"
    By BadCop in forum General Chat
    Replies: 15
    Last Post: 1st September 2006, 07:48 AM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •