Site hosted by Angelfire.com: Build your free website today!


This is a BATCH file named CDD.BAT


Two niggling problems that face DOS users are the inablity to change drive and
directory at once and the necessity of inserting hard-to-type punctuation between
drive names and every directory you list. CDD.BAT enables you to change drive
and directory without typing (or mistyping) a single colon or backslash. Instead,
you add an extra D at the end of a regular CD command and type only spaces
between drive and directory names. In the format shown here, CDD.BAT can move
three directories deep, but by adding extra IF and cd lines, you can navigate as
many directories as necessary. Pipe the commands' output to null (> NUL) to avoid
a stream of directory listings whenever you use CDD. Enter this listing in text
editor and save as an ASCII format (that is a fancy way of saying a text file (.txt how ever
instead of saving it as .txt save it as .bat, a windows program for this is called NOTEPAD)).
save it in your batch directory as CDD.BAT (if you use windows that would be c:\windows\command)


@ECHO OFF
%1:
FI (%2)==() GOTO END
CD \%2
CD %3 >nul
CD %4 > nul
:END

To change to the D: drive's LETTERS\BUSINESS directory, for examples, enter

CDD D LETTERS BBUSINESS

If you deal with differnt keyboard configurations, you may want to advoid typing
colons altogether. Use CDD just to change drives by typing CDD B or CDD A, for example.


written by:
MATTHEW LAKE
GO BACK TO DEBUG HOME PAGE

RETURN TO HOME PAGE