I did some rethinking on removing a directory from %PATH% (mentioned elsewhere on these forums) and thought it would also be nice to be able to change the order of directories in %PATH%. First idea was to (mis)use the history popup-window, as it has the possibility to change the order of items (Ctrl-Up/Down) That should go something like this: create a local (dir)histry, remove all items, add the directories from %PATH%, open history popup-window. Now you can delete entries (Del or Ctrl-D) and change the order. After that: read the history and re-create the path out of it. In (very raw) code: Code: @setlocal @echo off rem OPTION //ConsolePopupWindows=YES history /L @history /L /F do this in /t";" /L %PATH (@history /a %this) keystack PgUp do this in /p history (@set TEST=%TEST;%this) set TEST=%@RTRIM[;,%@LTRIM[;,%TEST]] echo PATH=%TEST "Problem" is the calling of the popup-window. Here it's done with keystack PgUp, but the script continues without waiting for this window to open. Does anyone have an idea how to work around that?