Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Batch file will not run

 
Jennifer Sohl
Ranch Hand
Posts: 455
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We have an app that our users are running from an icon on their desktop that points to a batch file.
For some reason now, the program does not run. It just brings up the DOS prompt, and then says 'pause'. Nothing has been changed in the batch file. I have no idea why it is doing this. Could someone give me a clue what to look for?
Thanks a million!
 
Michael Morris
Ranch Hand
Posts: 3451
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What's in the batch file Jennifer? Could it be that some resource (another bathfile or application?) that the batch file depends on has recently changed or been removed?
 
Jennifer Sohl
Ranch Hand
Posts: 455
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
:: start of bat file
set classpath=Y:\VSK Java Programs;c:\j2re1.4.1_01\bin;Y:\VSK Java Programs\jt400\lib\jt400.jar
javaw com.storekraft.ord.CVOrderEntry
pause
:: end of bat file
Above is the contents of the batch file. The only thing that I did, was made a change to a class, and copied the class file into the package that the batch file is looking at.
I tried running the program from TextPad after I made the change and no errors came up.
Is there any way I can make DOS print out what the problem is?
Thanks!
 
Michael Morris
Ranch Hand
Posts: 3451
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's been a while since I did any serious batch file writing, but I think something like:
 
Joel McNary
Bartender
Posts: 1840
Eclipse IDE Java Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Also, try java instead of javaw in the batch. If there is some problem in the code you will then be able to look at the command prompt to see what it might be.
Once you get it working, you can switch back to javaw.
 
Jennifer Sohl
Ranch Hand
Posts: 455
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the tip. I forgot I could use java vs. javaw. Found out I was getting a NoSuchMethod error. I had forgot to copy over a class file that was associated with the one I changed.
Thanks for all of your help!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic