Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

MANIFEST.MF and Windows 7 task scheduler

user5392751Oct 14 2013 — edited Oct 22 2013

Guys, sorry to bother you but I'm stuck with this annoying issue.

I have a java piece that I need to run from the windows task scheduler.

I was doing this in windows XP without any issues, now I moved to Win7 and it stopped working.

The particular thing is, I have a gigantic classpath here, so what I did is, use a MANIFEST.MF file to declare all the jars that I need to run my script, and then, a simple .cmd file to execute the script:

java -cp myApp.jar com.company.MainClass

If I run the .cmd file double clicking on it, or at the command line, everything goes fine.

If I call the same .cmd file from the windows task scheduler, I get all sort of NoClassDefFound exceptions, from missing libraries that are contained inside that MANIFEST.MF

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 19 2013
Added on Oct 14 2013
3 comments
405 views