HTFC Forums

H.T.F.C.

How To Fix Computers





Go Back   HTFC Forums > Software Newsgroups > Windows XP

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1  
Old 11-29-2007, 11:41 PM
ZenMasta
 
Posts: n/a
Default batch file, saving in a different folder than exe

I have a simple batch file that runs a script to convert a file. However I'm
having trouble figuring out how to put the result file in a folder other
then the java folder

cd C:\Program Files\Java\jre1.6.0_03\bin\
java.exe -jar C:\sax\saxon9.jar c:\sax\source\test.xml
c:\sax\switch-onix-tagnames-2.0.xsl
result-document=testymctesterson.xml

This script places the testymctesterson.xml in the bin folder but I want it
to go in c:\sax\export
I've tried putting a dir before the result-document file name but it doesn't
work. The script runs without error and no output file is created.



Reply With Quote
Sponsored Links
Fix your Windows Problems - FAST.
FREE Safe Scan Registry Check. Locate & Fix Errors in Minutes!
  #2  
Old 11-30-2007, 08:24 AM
Pegasus \(MVP\)
 
Posts: n/a
Default Re: batch file, saving in a different folder than exe


"ZenMasta" <me@nospam.com> wrote in message
news:uBSVlFuMIHA.3940@TK2MSFTNGP05.phx.gbl...
>I have a simple batch file that runs a script to convert a file. However
>I'm having trouble figuring out how to put the result file in a folder
>other then the java folder
>
> cd C:\Program Files\Java\jre1.6.0_03\bin\
> java.exe -jar C:\sax\saxon9.jar c:\sax\source\test.xml
> c:\sax\switch-onix-tagnames-2.0.xsl
> result-document=testymctesterson.xml
>
> This script places the testymctesterson.xml in the bin folder but I want
> it to go in c:\sax\export
> I've tried putting a dir before the result-document file name but it
> doesn't work. The script runs without error and no output file is created.
>
>
>


Try running the program from the target directory:
Line1=@echo off
Line2=cd /d c:\sax\export
Line3="C:\Program Files\Java\jre1.6.0_03\bin\java.exe" -jar
C:\sax\saxon9.jar c:\sax\source\test.xml c:\sax\switch-onix-tagnames-2.0.xsl
result-document=testymctesterson.xml

Alternatively you could copy or move to move testymctesterson.xml
to the desired target directory.


Reply With Quote
Sponsored Links
Fix your Windows Problems - FAST.
FREE Safe Scan Registry Check. Locate & Fix Errors in Minutes!
Reply


Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
batch file help DarthRevan561 Windows Vista 6 02-02-2008 01:00 AM
Need help with batch file n o s p a m p l e a s e Windows Vista 11 10-14-2007 07:35 AM
Batch file SANG Windows XP 2 09-13-2007 11:48 PM
Is there a batch command or other to set folder view to details behind-the-scenes? StargateFanFromWork Windows XP Basics 0 07-27-2007 06:35 PM
How do you copy a shortcut to a file with a batch file? Pegasus \(MVP\) Windows XP 11 04-13-2007 10:56 PM


All times are GMT. The time now is 08:59 AM.


Powered by vBulletin® Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0
© 2004 - 2007 Web-S-Sense Pty. Ltd. Usenet and forums posts © their respective authors.
Ad Management by RedTyger