开发者

Importing JSON_simple package problem

I am using JSON_simple library. I placed the jar files json-simple-1.1 and json-rpc in my classpath. It throws me a <package not found error>. I resolved the same issue by a method I read somewhere (to include the jars in a specific folder, which I don't remember now and hence the problem, but it was not a recommended solution). How to resolve it? I've hit the wall. Thanx..!开发者_JAVA技巧!


I see two possibilities:

  1. The jar is not really in the classpath used by the java-instance starting your program.
  2. You are not referencing the correct package-name in your import-statement spelling error. For json-simple it's: import org.json.simple or import org.json.simple.parser.

From remote I cannot analyse further your problem. Try to check your import-statement. If that is right, give us more information about how you include the jar into the classpath.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜