jQuery in Action, 2nd edition*
The moose likes Java in General and the fly likes not able identify class files in one of the jars. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "not able identify class files in one of the jars." Watch "not able identify class files in one of the jars." New topic
Author

not able identify class files in one of the jars.

abheeshek reddy
Ranch Hand

Joined: Nov 28, 2008
Posts: 41
Hi Guys,

i am facing below error while running one of my application in windows.


MessageXmlBuilder.java:12: cannot access com.bch.blah.blah.message.batch.MessageBatchConstants
bad class file: F:\jars\message_batch.jar(com/bch/blah/blah/message/batch/MessageBatchConstants.class)
class file has wrong version 50.0, should be 49.0

Please remove or make sure it appears in the correct subdirectory of the classpath.
import com.bch.blah.blah.message.batch.MessageBatchConstants;
^

and i am facing below error while running in Ubuntu

MessageXmlBuilder.java:335: error: batch cannot be resolved
private static Logger logger = Logger.getLogger(com/bch/blah/blah/message/batch/dao/MessageXmlBuilder);
^^^^^
MessageXmlBuilder.java:335: error: dao cannot be resolved
private static Logger logger = Logger.getLogger(com/bch/blah/blah/message/batch/dao/MessageXmlBuilder);
^^^
MessageXmlBuilder.java:335: error: MessageXmlBuilder cannot be resolved
private static Logger logger = Logger.getLogger(com/bch/blah/blah/message/batch/dao/MessageXmlBuilder);
^^^^^^^^^^^^^^^^^
32 problems (8 errors, 24 warnings)


please do suggest. ^
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19653
    
  18

The Java file has been compiled using a Java 6 compiler but you're using Java 5.0 to run it. Either use Java 6 to run, or compile for Java 5.0, using the -source and -target compiler flags.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
Consider Paul's rocket mass heater.
 
subject: not able identify class files in one of the jars.
 
Similar Threads
Not able to initialize the log4j.properties
Getting exception while instantiating servlet class
Why do we need mulitple loggers? - Log4j
Log 4j config issue
problems with packages and import statements