Shawn McGowen said:
I recently installed a resource kit for XP and it changed my default
command
prompt directory. Rather than copying ping.exe or ipconfig.ext etc. to
the
new default home drive I want my command prompt start on my C drive like
before. Now when I need to ping something or run other commands I keep
having to C: and then CD c:\winnt\system32. Can anyone let me know where
to
go to correct this? I'm not having much luck searching this topic so
hopefully there's a quick fix. Thanks,
Shawn
Shawn,
Many of the 'system' commands can be run no matter what your 'current
directory' assignment is.
For the ones that need to be run from a specific directory there are is a
nice method that involves setting some stuff in the registry.
It's called 'Command here' or 'Command prompt here' (or something to that
effect.
Once set, it gives you the option to right-click on any folder in Explorer
and choose Command here.
It will then open up the command prompt with that particular directory as
the current one.
Copy the below stuff into a file and name it cmdhere.inf.
right-click the file and choose 'install'.
Right-click a folder to see the result.
hth
george
; ----------------------------------
; "CMD Prompt Here" PowerToy
;
; Copyright 1996 Microsoft Corporation
;
[version]
signature="$CHICAGO$"
[CmdHereInstall]
CopyFiles = CmdHere.Files.Inf
AddReg = CmdHere.Reg
[DefaultInstall]
CopyFiles = CmdHere.Files.Inf
AddReg = CmdHere.Reg
[DefaultUnInstall]
DelFiles = CmdHere.Files.Inf
DelReg = CmdHere.Reg
[SourceDisksNames]
55="CMD Prompt Here","",1
[SourceDisksFiles]
CmdHere.INF=55
[DestinationDirs]
CmdHere.Files.Inf = 17
[CmdHere.Files.Inf]
CmdHere.INF
[CmdHere.Reg]
HKLM,%UDHERE%,DisplayName,,"%CmdHereName%"
HKLM,%UDHERE%,UninstallString,,"rundll32.exe
syssetup.dll,SetupInfObjectInstallAction DefaultUninstall 132
%17%\CmdHere.inf"
HKCR,Directory\Shell\CmdHere,,,"%CmdHereAccel%"
HKCR,Directory\Shell\CmdHere\command,,,"%11%\cmd.exe /k cd ""%1"""
HKCR,Drive\Shell\CmdHere,,,"%CmdHereAccel%"
HKCR,Drive\Shell\CmdHere\command,,,"%11%\cmd.exe /k cd ""%1"""
[Strings]
CmdHereName="CMD Prompt Here"
CmdHereAccel="CMD &Prompt Here"
UDHERE="Software\Microsoft\Windows\CurrentVersion\Uninstall\CmdHere"
;-------------------------------------