Jump to content

Command Prompt


linolium

Recommended Posts

I don't know how it happened, but since installing Windows XP, some setting must have been changed that caused this behaviour. I am reinstalling Windows, and want to keep this behaviour, but cannot for the life of me figure out how!

I have an explorer window open to, for example, D:\Applications (and the window is focused). I then open the command prompt either clicking Start, Run, typing cmd, and hitting "OK," or just using WINKEY+R to get to the run window. The path of the command prompt window that opens up is the same as the explorer window that previously had focus (D:\Applications).

On a normal fresh install of Windows XP, the path will always be C:\Documents and Settings\<user>\Desktop (afaik), unless the default path is changed.

Note: this is not the "Open Command Prompt Here" Powertoy, and nor do I want to use it. I would like to be able to mirror the described behaviour above, not install this Powertoy.

So my question is: has anyone else ever experienced this [extremely helpful] behaviour, and do they know how they configured their system to function that way?

Attached is an image describing this behaviour.

magicmd.png

Link to comment
Share on other sites


I believe if you go here...

http://www.pctools.com/registry-mechanic/i...w/registry-fix/

you can find a tweak that does that for you. It is just a matter of hacking around some of the registry values.

Also I am curious while we are in the command prompt thread if it is possible to not display the entire directory path of the present working directory and just show the name of only the directory in the command prompt. For example suppose you are in C:\Program Files\Java\jdk1.5.0_02\bin and so all you would want to see in your cmd prompt instead of the whole path would be C;\$bin or something like that so it does not take up so much of the dos window space.

Thanks in advance.

Link to comment
Share on other sites

I believe if you go here...

http://www.pctools.com/registry-mechanic/i...w/registry-fix/

you can find a tweak that does that for you. It is just a matter of hacking around some of the registry values.

Also I am curious while we are in the command prompt thread if it is possible to not display the entire directory path of the present working directory and just show the name of only the directory in the command prompt. For example suppose you are in C:\Program Files\Java\jdk1.5.0_02\bin and so all you would want to see in your cmd prompt instead of the whole path would be C;\$bin or something like that so it does not take up so much of the dos window space.

Thanks in advance.

Hi suryad, and thanks for your reply.

I looked around on that site but unfortunately could only find the Open Command Prompt Here registry hack, which is exactly what the Powertoy does. Is this the one you had in mind, or were you referring to some other one?

And in response to your other problem, the prompt is controlled by the "prompt" environment variable. Type set PROMPT to see what it is currently set to, and set PROMPT="......" to set it. I don't know if there is a way to get the lowest directory you're currently in shown on there, but you can certainly get rid of the path completely.

Link to comment
Share on other sites

Try This

I Ran This From Desktop And It Will Return This

D:\Doc That Is The Title It Will Get

Echo Off && Cls && Mode 55,3 && color 3f

set T=%CMDCMDLINE:~9,6%

Title = %T%

Echo. && echo %T% && set /p = Press Key To Close

Edited by gunsmokingman
Link to comment
Share on other sites

  • 2 months later...

yeah i remember having this feature... but i dont know how it happened... the previous active window was always the default path in the cmd...

no formatted my hard drive, but dont know how to get this feature back... it is very helpul

if you find out, let me know please

kindest regards

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...