From: John G. <jge...@ny...> - 2001-05-30 18:39:44
|
The Console shell is not a true shell but a fancy wrapper around Runtime.exec(). Under JDK1.3, the apparent working directory you manipulate with 'cd' and 'pwd' is a data member maintained by the Console's shell object and passed to Runtime.exec() as the working directory of the process in which the Console command runs. It is not part of the current environment, however. The working directory of the exec() call itself is the working directory of the JVM, which cannot be changed from within Java. John > I cannot seem to get the console to run anything from the current > directory. > If what I want to run is on PATH or I fully specified the file to > run, then > the console plugin will run it fine. If I try to run a file in the current > directory, I get an I/O error. > > Any hints? > > Below is the output from the console... > > > cd c:\ > Working directory is now C:\ > > pwd > C:\ > > test.cmd > I/O error: CreateProcess: test.cmd error=2 > > c:\test.cmd > :: = number of XSL transform processor to use > :: = xsl description of transform > :: = document to transform > :: > :: Creates a HTML file in the same directory as with the extension .html > :: > :: Transforms available: > :: 1 - Saxon 5.3 > :: 2 - Sablot > :: 3 - Uxsl > :: 4 - Saxon 5.4 > :: 5 - Saxon 5.5.1 > Process c:\test.cmd exited with code 0 > |