+ Post New Thread
Page 3 of 3 FirstFirst 123
Results 31 to 35 of 35
Scripts Thread, Setting Printers Based On Room Location in Coding and Web Development; Originally Posted by mark which is... [hehe] Is that it? is that the path? - not a reference to any ...
  1. #31
    DMcCoy's Avatar
    Join Date
    Oct 2005
    Location
    Isle of Wight
    Posts
    3,476
    Thank Post
    10
    Thanked 500 Times in 440 Posts
    Rep Power
    114

    Re: Setting Printers Based On Room Location

    Quote Originally Posted by mark
    which is... [hehe]

    Is that it? is that the path? - not a reference to any specific path or machine - but syntax for the WMI root path generically?
    It belongs on the end of the second line but got wrapped.

    I don't know much about WMI, but I'm guessing the "." bit sets it to the local machine. You can see it in: Computer Managment, WMI Control then right click, properties, security.

  2. #32

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

    Re: Setting Printers Based On Room Location

    Its a string concatination. The full path for the GetObject call ends up as:

    Code:
    winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2
    First bit is the protocol (winmgmts), second bit is the impersonation level ({impersonationLevel=impersonate}) last bit is the path, the \\. means the local machine. You could use \\RANDOMSERVER01 instead if you wanted to access things remotely over the network. Last bit is the WMI root path as I've explained.

    Why is it such an unobvious mess of ASCII? I've no idea, ask Microsoft.

  3. #33
    mark's Avatar
    Join Date
    Jun 2005
    Posts
    3,972
    Thank Post
    257
    Thanked 49 Times in 45 Posts
    Blog Entries
    2
    Rep Power
    46

    Re: Setting Printers Based On Room Location

    Hey- run the script [as is! :P] and it worked a treat! thanks

  4. #34

    Join Date
    May 2006
    Posts
    159
    Thank Post
    5
    Thanked 10 Times in 5 Posts
    Rep Power
    19

    Re: Setting Printers Based On Room Location

    Am I allowed to do a blatant ad for a small utility I wrote and just uploaded to the download section?

    Makes things a whole lot easier, no spyware or other junk, just posting something hopefully others will find useful.

    http://printing.networkstuff.co.uk

    for instructions and download.


  5. #35

    Ric_'s Avatar
    Join Date
    Jun 2005
    Location
    London
    Posts
    7,592
    Thank Post
    109
    Thanked 770 Times in 598 Posts
    Rep Power
    182

    Re: Setting Printers Based On Room Location

    @klawd: Free utilities written by our members are welcomed and often encouraged. After all, why re-invent the wheel?

    If you would like to open the source, I'm sure our members would love to help you develop it further.

SHARE:
+ Post New Thread
Page 3 of 3 FirstFirst 123

Similar Threads

  1. Replies: 50
    Last Post: 19th May 2008, 12:24 PM
  2. Room Booking Database/Web based (.asp)
    By danIT in forum Downloads
    Replies: 131
    Last Post: 7th November 2007, 10:20 AM
  3. Mapping Printers based on Location
    By NeoNemesis in forum Windows
    Replies: 11
    Last Post: 6th August 2007, 08:03 AM
  4. Assinging printers to clients based on OU
    By originofsymmetry in forum Network and Classroom Management
    Replies: 3
    Last Post: 11th July 2007, 06:02 AM
  5. Thinking of setting up a Thin Client in on room.
    By tosca925 in forum Thin Client and Virtual Machines
    Replies: 5
    Last Post: 29th June 2006, 07:53 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
  •