tech gurus please help - Techist - Tech Forum

Go Back   Techist - Tech Forum > Computer Software > Microsoft Windows and Software
Closed Thread
Thread Tools Display Modes
Old 02-01-2005, 06:52 AM   #1 (permalink)
Newb Techie
Join Date: Aug 2004
Posts: 10
Send a message via Yahoo to microcontroller
Cool tech gurus please help

when we type cmd in the 'run' box and press enter the command prompt opens up and by default C:\> (or) d:\> is shown.

can we change that default path to the path of our choice?

thank you

microcontroller is offline  
Old 02-01-2005, 08:41 AM   #2 (permalink)
It's all just 1s and 0s
office politics's Avatar
Join Date: Jan 2004
Location: in the lab
Posts: 6,555
Send a message via MSN to office politics


In Win2k or XP cmd.exe
"the Prompt" runs with the default directory of:
C:\Documents and Settings\[LogonUserName]

This behavior you see is by design, but here's a workaround:

1. Click Start -> Run
2. Type "Regedit" (without quotes) and click OK
3. In the Registry Editor go to
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Command Processor
double-click the "AutoRun" value
4. Add the data: cd [path]

where [path] is the path to the folder you want the command prompt to open at.

"cd \" - will open in the root of the current drive
"cd c:\windows" - will open in the Windows folder
"cd %WinDir%\System32" - will open in the System32 folder

5. Click OK and close the Registry Editor

The command prompt should now open at the specified folder.

This will affect all users of the system. If you wish to make this settings different for different users, simply add the 'AutoRun' value to the following key instead:
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Command Processor

This runs a standard Change Directory (CD) command automatically on launching the cmd. This can be adapted to run other commands. For example would cause the prompt to open in the Windows directory and produce a listing of the contents:

"cd %windir% && dir"

Note: The entries in 'AutoRun' are ignored if the command prompt is opened with a /D switch:

"cmd /D"

office politics is offline  
Old 02-02-2005, 12:41 AM   #3 (permalink)
Newb Techie
Join Date: Aug 2004
Posts: 10
Send a message via Yahoo to microcontroller

thank you very much csamuels
it works !!!
microcontroller is offline  
Closed Thread

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Our Communities

Our communities encompass many different hobbies and interests, but each one is built on friendly, intelligent membership.

» More about our Communities

Automotive Communities

Our Automotive communities encompass many different makes and models. From U.S. domestics to European Saloons.

» More about our Automotive Communities

Marine Communities

Our Marine websites focus on Cruising and Sailing Vessels, including forums and the largest cruising Wiki project on the web today.

» More about our Marine Communities

Copyright 2002-2015 Social Knowledge, LLC All Rights Reserved.

All times are GMT -5. The time now is 05:22 AM.

Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2016, vBulletin Solutions, Inc.