0

I've added a jar into project, but my app can not see this. IDE doesn't say something wrong during devepoling, but not after deploy.

enter image description here

Does it mean, that smsj.jar is not in the CLASSPATH?

Tony
  • 3,605
  • 14
  • 52
  • 84
  • possible duplicate of [How to Solve java.lang.NoClassDefFoundError?](http://stackoverflow.com/questions/17973970/how-to-solve-java-lang-noclassdeffounderror) – flotothemoon Jul 30 '14 at 06:38
  • Likely eclipse isn't refreshing the classpath... Can you try doing right click on the `SMSCWeb` project and click on `Refresh` and see if it works? – BackSlash Jul 30 '14 at 07:14
  • Looks like your project is using maven. I think you added the jar only to your eclipse classpath? (I.e. using Eclipse project properties "Build Path". This way you are telling the IDE compiler about the jar, but nobody else knows about it. That would explain the CNF on deploy while it compiles in the IDE. You should probably add this jar as a dependency in your maven pom instead. If the jar is available in maven central its easy, otherwise could be a little trickier. – Kris Jul 31 '14 at 15:42

1 Answers1

0

As the image says you have just added the smsj.jar.

But the smsj.jar has dependency on some other jars because of that you are getting the NoClassDefFoundError.

Try to include the dependecies of smsj as well which are slf4j-simple , rxtx, javacomm.

SparkOn
  • 8,806
  • 4
  • 29
  • 34
  • @BackSlash Hi correct me if im wrong OP never said he has problem with resolving the imports. Its `NoClassDefFoundError` which may be because he dont have the dependencies – SparkOn Jul 30 '14 at 07:17