Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
334 views
in Technique[技术] by (71.8m points)

Getting NoClassDefFoundError when using common.lang.StringUtils in android java code?

I am getting this error:-NoClassDefFoundError wherever the code is using StringUtils class or methods .I have correctly added the jar files to the code and is not showing any kind of error in my code(Using Eclipse Indigo).

Is there any kind of point I am missing out. I have used this jar file in other projects but they worked properly.

Please help If any one is getting similar kind of problem?Thanks

Question&Answers:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Yes, this because of your .jar file didn't import properly. Follow below steps -

  1. Place your .jar file in your project's libs folder .

  2. Import it into your project. And, GoTo project -> properties -> Java build path -> order tab.

  3. Check, whether your .jar file checked and placed in order of 1st. This is the main thing.

Hope these steps helps you. Have a look at below image -

enter image description here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...