Windows 10: How do I change environment variables in regular User account???

Discus and support How do I change environment variables in regular User account??? in Windows 10 Support to solve the problem; (The number of primitive bugs in version 1511 is just imagination-defying.) Open Control Panel. Open User Accounts applet. On the left there's a... Discussion in 'Windows 10 Support' started by AndreyT, Nov 17, 2015.

  1. AndreyT Win User

    How do I change environment variables in regular User account???


    (The number of primitive bugs in version 1511 is just imagination-defying.)

    Open Control Panel. Open User Accounts applet. On the left there's a link that says Change my environment variables.


    How do I change environment variables in regular User account??? [​IMG]


    Clicking on that link... does nothing (!!!). The link is simply dead.

    What on Earth is going on??? How are we supposed to change environment variables in non-Administrator accounts now? This Change my environment variables link in User Accounts was provided specifically for that purpose. There's no other natural way to do it.

    I know that there are workarounds for this (all ugly), but... WTH? Did they do even basic testing on this 1511 release???

    P.S. Just confirmed that pre-1511 Windows 10 works normally in that regard. This damage was done specifically by 1511 update.

    :)
     
    AndreyT, Nov 17, 2015
    #1
  2. ustulo Win User

    Edit Environment Variables of Standard User Account

    In Windows 10, how can I set user-level (not system wide) environment variables for a standard user account? To clarify: I'm not talking about editing system environment variables. Also, just running the System app in Control Panel as admin won't work because
    that would set the environment variables for that admin user.

    When I go to Control Panel -> User Accounts, then click the "Change my environment variables" link in the left-hand action pane, nothing happens.

    If I go to the search box on the task bar and type "environment", then click "Edit environment variables for your account", nothing happens.

    Currently I have JAVA_HOME set to an incorrect value in my user account, which is a standard user not an admin. If I edit environment variables as admin, it does not show up in the system environment variables nor in the user environment variables (since
    the Administrator account is a different user).
     
    ustulo, Nov 17, 2015
    #2
  3. NHartsell Win User
    I can't set environment variables for my user account

    To edit Environment Variables in Windows 10 for your user account you can

    • Search for "environment" and select "Edit environment variables for your account"

    • Go to Control Panel > User Accounts > User Accounts > Change my environment variables

    However, neither of these works for me. I get no response.

    I don't know if this is a bug in Windows 10 or just isn't working on my machine.

    How can I troubleshoot this?
     
    NHartsell, Nov 17, 2015
    #3
  4. Ztruker Win User

    How do I change environment variables in regular User account???

    Right click on This PC and select Properties.
    Click on Advanced system settings on the left.
    Enter the password for your administrator level account.

    Now you can change environment variables.

    Don't know why doing it through Control Panel doesn't also prompt you for administrator credentials, it should.
     
    Ztruker, Nov 18, 2015
    #4
  5. AndreyT Win User
    No, you can't.

    By using this method you will gain access to system-wide environment variables and to user-specific environment variables of the administrator, whose password you just entered. This is what you will edit there.

    I don't want to edit administrator's variables.

    I want to edit user-specific environment variables of my current non-admin user. There's no other direct way to do it besides going through the Control Panel, as I described above. The link in User Accounts exists specifically for that purpose.

    The reason it doesn't ask you for password is exactly that: this method will allow a non-admin user to edit their own user-specific environment variables only and nothing else.

    One more time: this issue is specifically and exclusively about the top part of the environment editor window


    How do I change environment variables in regular User account??? [​IMG]
     
    AndreyT, Nov 18, 2015
    #5
  6. Ztruker Win User
    Okay, agree you can change user and system wider variables, but at least you can change user specific variables there, just don't mess with the system stuff.

    I know it's not a fix and there is definitely a problem but at least this allows you to do what you need to do.

    Have you reported this to Microsoft via the Windows Feedback option?
     
    Ztruker, Nov 19, 2015
    #6
  7. AndreyT Win User
    Sigh... No, it doesn't allow me to do what I need to do. My previous message has a very detailed explanation of why your "Advanced system settings" approach is not even close to what I need to do.

    One more time: I need to edit user-specific variable of a non-admin user, say, Alice. The approach suggested by you will allow me to edit user-specific variables of user Admin​ instead. Even if you are currently logged in as Alice, your "Advanced system settings" approach will take you to the user-specific variables for Admin. Are you aware of that little detail?

    Do you see the problem? I want to edit variables for Alice. Alice, Alice, Alice specifically. Not Admin. Alice. You suggestion cannot and will not edit Alice. Your suggestion will edit Admin. See the problem?

    If something is still not clear to you - feel free to ask.

    And yes, I reported this problem to Microsoft. They acknowledged the bug, asking me to create a Feedback entry, while they are creating their own entry from their end.
     
    AndreyT, Nov 19, 2015
    #7
  8. Ztruker Win User

    How do I change environment variables in regular User account???

    Okay, I do see it now. Sorry for the thick headedness *Sad

    If we knew what clicking on that link was supposed to launch then we'd have a chance to make it work but as it stands, I don't see any way to fix it.

    As a work around, maybe this can work?

    HowTo: Set an Environment Variable in Windows - Command Line and Registry

    Code: SetX has three ways of working: Syntax 1: SETX [/S system [/U [domain\]user [/P [password]]]] var value [/M] Syntax 2: SETX [/S system [/U [domain\]user [/P [password]]]] var /K regpath [/M] Syntax 3: SETX [/S system [/U [domain\]user [/P [password]]]] /F file {var {/A x,y | /R x,y string}[/M] | /X} [/D delimiters] Description: Creates or modifies environment variables in the user or system environment. Can set variables based on arguments, regkeys or file input. Parameter List: /S system Specifies the remote system to connect to. /U [domain\]user Specifies the user context under which the command should execute. /P [password] Specifies the password for the given user context. Prompts for input if omitted. var Specifies the environment variable to set. value Specifies a value to be assigned to the environment variable. /K regpath Specifies that the variable is set based on information from a registry key. Path should be specified in the format of hive\key\...\value. For example, HKEY_LOCAL_MACHINE\System\CurrentControlSet\ Control\TimeZoneInformation\StandardName. /F file Specifies the filename of the text file to use. /A x,y Specifies absolute file coordinates (line X, item Y) as parameters to search within the file. /R x,y string Specifies relative file coordinates with respect to "string" as the search parameters. /M Specifies that the variable should be set in the system wide (HKEY_LOCAL_MACHINE) environment. The default is to set the variable under the HKEY_CURRENT_USER environment. /X Displays file contents with x,y coordinates. /D delimiters Specifies additional delimiters such as "," or "\". The built-in delimiters are space, tab, carriage return, and linefeed. Any ASCII character can be used as an additional delimiter. The maximum number of delimiters, including the built-in delimiters, is 15. /? Displays this help message. NOTE: 1) SETX writes variables to the master environment in the registry. 2) On a local system, variables created or modified by this tool will be available in future command windows but not in the current CMD.exe command window. 3) On a remote system, variables created or modified by this tool will be available at the next logon session. 4) The valid Registry Key data types are REG_DWORD, REG_EXPAND_SZ, REG_SZ, REG_MULTI_SZ. 5) Supported hives: HKEY_LOCAL_MACHINE (HKLM), HKEY_CURRENT_USER (HKCU). 6) Delimiters are case sensitive. 7) REG_DWORD values are extracted from the registry in decimal format. Examples: SETX MACHINE COMPAQ SETX MACHINE "COMPAQ COMPUTER" /M SETX MYPATH "%PATH%" SETX MYPATH ~PATH~ SETX /S system /U user /P password MACHINE COMPAQ SETX /S system /U user /P password MYPATH ^%PATH^% SETX TZONE /K HKEY_LOCAL_MACHINE\System\CurrentControlSet\ Control\TimeZoneInformation\StandardName SETX BUILD /K "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\CurrentBuildNumber" /M SETX /S system /U user /P password TZONE /K HKEY_LOCAL_MACHINE\ System\CurrentControlSet\Control\TimeZoneInformation\ StandardName SETX /S system /U user /P password BUILD /K "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\ CurrentVersion\CurrentBuildNumber" /M SETX /F ipconfig.out /X SETX IPADDR /F ipconfig.out /A 5,11 SETX OCTET1 /F ipconfig.out /A 5,3 /D "#$*." SETX IPGATEWAY /F ipconfig.out /R 0,7 Gateway SETX /S system /U user /P password /F c:\ipconfig.out /X[/quote]
     
    Ztruker, Nov 20, 2015
    #8
  9. AndreyT Win User
    AndreyT, Nov 24, 2015
    #9
  10. Ztruker Win User
    No, you use SET to delete them.

    setx abc=123 .... abc is set to 123
    set abc ---------- abc is null and disappears
     
    Ztruker, Nov 25, 2015
    #10
  11. AndreyT Win User
    Um... No, cannot use 'SET' to delete environment variables in the context of this issue. 'SET' is completely irrelevant here.

    • Firstly, the topic here is, one more time, permanent changes to user environment variables. 'SET' does not and cannot make permanent changes. 'SET' can only make changes to the environment of the current process. All these changes are lost once the process terminates. So, 'SET' is not applicable in this topic at all.

      This is exactly why we have 'SETX'. The whole point of 'SETX's existence is that changes made by 'SETX' are permanent.

    • Secondly, I don't know where you got the idea that 'set abc' will make variable 'abc' disappear (?). If variable 'abc' does not exist, then 'set abc' is simply invalid. If variable 'abc' exists, then 'set abc' will simply display its value.

      The proper syntax for "deleting" a variable using 'SET' is 'set abc='. Note the '=' part. However, as I said above, 'SET' is completely irrelevant here.
     
    AndreyT, Nov 25, 2015
    #11
  12. rattus Win User
    this annoys the hell out of me on new build PC's
    I've not come to the bottom of it yet , however what I do is
    :-
    Win X - y [ to get t the system display ]
    advanced system settings
    Environment Variables
    add the ones you want
    ...

    I've found that after a while [it must be something else I do ] then you can edit the user Enviorment variables
     
    rattus, Jan 3, 2016
    #12
  13. RolandJS Win User

    How do I change environment variables in regular User account???

    Be careful about changing those variables, I did that, ended up putting them back to default, 'cause a few program installations which were "hard-wired" to do things only one certain way, did not react well to the "missing" default setting.
     
    RolandJS, Jan 3, 2016
    #13
  14. NovHak Win User
    AndreyT, I'm with you on this one, and I have to say some parts of this OS look really amateurish...

    Anyway, if you want to be able to change the environment variables as conveniently as before, you can make some slight changes to the SystemPropertiesAdvanced executable, located inside the System32 folder. I mean a copy of it, of course.

    You have to change its manifest so that it can run as a regular user. Fortunately, there's a nice tool called CFF Explorer that can do just that, part of the Explorer suite at ntcore.com. Open the executable with CFF Explorer, go to Resource Editor => Configuration Files => 1. Right click, choose Save Resource (Raw), and save it wherever you like, a txt extension would be a good choice. Open the saved file with a text editor, it's the manifest. You have to replace "requireAdmin" with "asInvoker". In the CFF Explorer window, right click the resource again, and choose "Replace resource", then select the file you just edited. Finally click the save button in the CFF Explorer menu bar, overwrite the executable, and voil , you can change non admin user environment variables with it.

    Notice how buttons to change the system env variables are greyed out. This means some people thought it can be executed as non admin, I guess...

    In case you're lazy or in a hurry, here's the file (64-bit), signed by me in an attempt to add some security. My SHA1 fingerprint is ‎94 bf 0f 7d 05 51 5a 80 ba 1d e2 67 7c d7 ed 4e ec ae fd cd.

    I can send you an unsigned version if you prefer, and/or its 32-bit counterpart, located in the SysWOW64 directory for 64-bit systems.

    Hope this helps !
     
    NovHak, Apr 4, 2018
    #14
Thema:

How do I change environment variables in regular User account???

Loading...
  1. How do I change environment variables in regular User account??? - Similar Threads - change environment variables

  2. Environment Variables, User variables for System Admin

    in Windows 10 Gaming
    Environment Variables, User variables for System Admin: I was looking at the 'User variables for System Admin' one day and saw my name spelled '*****'. I didn't care for that name and without thinking changed the name. Now all my music, photos & docs are gone. How can I undo that already tried 'System Restore'?...
  3. Environment Variables, User variables for System Admin

    in Windows 10 Software and Apps
    Environment Variables, User variables for System Admin: I was looking at the 'User variables for System Admin' one day and saw my name spelled '*****'. I didn't care for that name and without thinking changed the name. Now all my music, photos & docs are gone. How can I undo that already tried 'System Restore'?...
  4. Environment Variables, User variables for System Admin

    in Windows 10 Network and Sharing
    Environment Variables, User variables for System Admin: I was looking at the 'User variables for System Admin' one day and saw my name spelled '*****'. I didn't care for that name and without thinking changed the name. Now all my music, photos & docs are gone. How can I undo that already tried 'System Restore'?...
  5. environment variables

    in Windows 10 Software and Apps
    environment variables: Cant get the modal window when editing my system variables from the environment variables areai get this windowand i want this window https://answers.microsoft.com/en-us/windows/forum/all/environment-variables/07d24fc8-345d-4062-8169-3fa9bb16a049
  6. environment variables

    in Windows 10 Customization
    environment variables: Hi, another question from a noob. I see in my PC environment variables at the bottom of the list a sole entry called ZES_ENABLE SYSMAN 1 .I am a sole PC home windows 10 user who only really games a lot. Should this be here, i can only find entries for this in the...
  7. regarding path variable of user variable of environment variable

    in Windows 10 Customization
    regarding path variable of user variable of environment variable: please help me fast, I accidentally deleted path variable of user variable ..... I want to restore it. the real situation is I cannot run android studio project and it shows error - " unable to start daemon process............This problem might be caused by incorrect...
  8. environment variable

    in Windows 10 Customization
    environment variable: What would happen when we deleted all the environment variable system directory. https://answers.microsoft.com/en-us/windows/forum/all/environment-variable/723a4cb6-5baf-4907-a56b-614f35d77da5
  9. User Environment Variable

    in Windows 10 Software and Apps
    User Environment Variable: Created an User Environment variable in Environment variable page in UI. It is seen in both UI and command prompt(Using set command). After restart it is not seen in command prompt when set command is used. Please help....
  10. Environment Variables

    in Windows 10 BSOD Crashes and Debugging
    Environment Variables: what will happen if i accidentally delete one of those environment variables without realizing it ? and how to fix it ? https://answers.microsoft.com/en-us/windows/forum/all/environment-variables/fedbdf36-ce8e-4861-a775-1dc62dd1c67e