+ Post New Thread
Results 1 to 4 of 4
Windows Server 2008 R2 Thread, How to create a custom Environment Variable? in Technical; The school I support is part of LGFL and as such they log into their StaffMail accounts with a USO ...
  1. #1

    Join Date
    Oct 2011
    Location
    United Kingdom
    Posts
    2
    Thank Post
    0
    Thanked 0 Times in 0 Posts
    Rep Power
    0

    Question How to create a custom Environment Variable?

    The school I support is part of LGFL and as such they log into their StaffMail accounts with a USO username and password.

    I want to create a PRF file for Outlook so that staff can login to any computer and Outlook will setup their account and just ask for a password. I've done this before where users were using the same username as their email address login and it worked well but in this instance the USO accound isn't known by the local network.

    What I need is to setup USurname in AD so that %USOAccount% returns USuren45.307

    That way I can set LGFLMAIL\%USOAccount% in my PRF file to automatically populate the username and %username%@schoolname.lea.sch.uk will be the users email address.

    Has anyone done this?
    Last edited by TwoPlus1; 28th October 2011 at 12:00 PM.

  2. #2

    Join Date
    Nov 2010
    Location
    Sydney, Australia
    Posts
    24
    Thank Post
    3
    Thanked 2 Times in 2 Posts
    Rep Power
    8
    I haven't tried it but the way I would do it is to store the value in either a custom AD Attribute or an unused standard attribute. Then use either VBScript or Powershell to lookup the attribute in AD for the current user and set that as an environmental value.
    This could then be run as a logon script for your users.

  3. #3

    jinnantonnixx's Avatar
    Join Date
    Mar 2011
    Location
    In the Calamatorium.
    Posts
    1,991
    Thank Post
    114
    Thanked 506 Times in 341 Posts
    Blog Entries
    2
    Rep Power
    286
    We use the Setx.exe command (built-in to Windows) to do something similar. It's a bit old-school, but it works well enough.

    As ruddj suggested, build up your variables then use setx to set them in a logon script.

    More info here:
    Setx - Set environment variables

  4. #4

    Join Date
    Jun 2011
    Location
    London
    Posts
    8
    Thank Post
    1
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    Quote Originally Posted by TwoPlus1 View Post
    The school I support is part of LGFL and as such they log into their StaffMail accounts with a USO username and password.

    I want to create a PRF file for Outlook so that staff can login to any computer and Outlook will setup their account and just ask for a password. I've done this before where users were using the same username as their email address login and it worked well but in this instance the USO accound isn't known by the local network.

    What I need is to setup USurname in AD so that %USOAccount% returns USuren45.307

    That way I can set LGFLMAIL\%USOAccount% in my PRF file to automatically populate the username and %username%@schoolname.lea.sch.uk will be the users email address.

    Has anyone done this?
    Hi TwoPlus1

    Have you had any luck with this as I am having the same problem?
    Any help will be appreciated.

    Thanks

SHARE:
+ Post New Thread

Similar Threads

  1. Replies: 3
    Last Post: 14th September 2011, 10:25 PM
  2. How to create a certificate request for an Exchange 2007 UCC
    By Dos_Box in forum How do you do....it?
    Replies: 11
    Last Post: 27th April 2009, 06:42 PM
  3. advice on how to create .adm file
    By PEO in forum General Chat
    Replies: 11
    Last Post: 8th May 2008, 02:00 PM
  4. Strong passwords: How to create and use them
    By FN-GM in forum General Chat
    Replies: 0
    Last Post: 15th August 2007, 11:17 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
  •