Skip to content
View in the app

A better way to browse. Learn more.

MSFN

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

change environment variables + opening cmd shell in a folder

Featured Replies

Hi,

I am trying to come up with a simple way that i can change environment variables and then open a cmd shell in an folder

and see the changed variables without re-booting the machine.

I run Cmd shell in 2 different ways

1. START-Run-cmd

This always opens in some Windows directory.

2. In explorer, i can right click on a folder and open a Cmd shell in that directory. Microsoft have a support tool to

do this, but you can do the same with the following registry entries.

[HKEY_LOCAL_MACHINE\Software\Classes\Folder\Shell]

[HKEY_LOCAL_MACHINE\Software\Classes\Folder\Shell\AcraFlow: Open Cmd Shell]

[HKEY_LOCAL_MACHINE\Software\Classes\Folder\Shell\AcraFlow: Open Cmd Shell\command]

@="cmd.exe /k pushd %L"

I have found 2 useful utilites for setting environment variables, setx.exe and setenv.exe.

What i have done so far is

1. created a .bat file to set the environment variable to what i want. I double click on the file to set the variable.

setenv -u MYVARIABLE myvalue

2. If i open a command shell as follows, and run the set command, i see the variable MYVARIABLE

START-Run-cmd

3. However, if i open a command shell using a right click on a folder in Explorer, and run the set command, i dont see the variable.

Why is this? Its very frustrating.

Any help would be really appreciated.

Thanks

Delbert.

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.