DOS in XP

  • Thread starter Thread starter LLL
  • Start date Start date
L

LLL

I need to change directories in DOS on my WINXP machine. I
need to be in the directory,
C:\jakarta-tomcat-4.1.29\webapps, so I can run the jar
utility in Java that enables me to set-up a WAR file. Why
can't I change up to any file that starts with J? I can
change up to my temp file, or Windows file, or Inetpup
file, but no file that starts with J. If the file starts
with J, I get Invalid directory.
 
LLL said:
I need to change directories in DOS on my WINXP machine. I
need to be in the directory,
C:\jakarta-tomcat-4.1.29\webapps, so I can run the jar
utility in Java that enables me to set-up a WAR file. Why
can't I change up to any file that starts with J? I can
change up to my temp file, or Windows file, or Inetpup
file, but no file that starts with J. If the file starts
with J, I get Invalid directory.


I think you are typing something incorrectly.

If I am at a DOS prompt (command prompt actually) in Windows XP (Home or
Professional) and have the directories you mentioned.. here are the
scenarios I found:

If I am at C:\>, I can type:

cd "jakarta-tomcat-4.1.29"
cd "webapps"

or

cd "\jakarta-tomcat-4.1.29\webapps"

or

chdir "jakarta-tomcat-4.1.29"
chdir "webapps"

or

chdir "\jakarta-tomcat-4.1.29\webapps"

From anywhere on the C:\ drive (meaning C:\temp> or C:\windows\system32> and
basically any subdirectory on the C drive, but with the root being C at the
command prompt) I could typoe either of these:

cd "\jakarta-tomcat-4.1.29\webapps"

or

chdir "\jakarta-tomcat-4.1.29\webapps"


If I was writng a batch/cmd script to do it, I would want to be sure I was
starting at the root or at least on the C:\ drive. I would write a script
like this:

@ECHO OFF
C:
CD "\jakarta-tomcat-4.1.29\webapps"
SOME COMMAND INSIDE THAT DIRECTORY (since it is my working directory now.)


Notice I use the quotes. They "shouldn't be" needed, but it doesn't hurt.
 
Hello LLL,
so from a C prompt
C:\ make sure you are at C:\
Do a dir jaka*.*
does it list the directory?
try entering cd jakar*
yuo can use wildcard.
If that doesn't work, locate cmd.exe (or command.com)and copy it to that
directory.
Click on it and the cmd prompt will open in the directory the file is
located in.

Can you create a new folder as a test
MD JJJ
now trying changing directory to JJJ
cd JJJ
Does that work?

There is no reason that I am aware of that would make directories starting
with one letter not available.

Thanks,
Darrell Gorter[MSFT]

This posting is provided "AS IS" with no warranties, and confers no rights
--------------------
 
Back
Top