0

I am getting java.lang.ClassNotFoundException: while loading this class "fol.Classname" like this

        classLoader.loadClass("fol.Classname");

this class(Classname.class) present in jar(location at /home/user/abc.jar) file in folder "fol". while my project at /home/user/Download/Workspace/.. Kindly correct me what i am doing wrong?

Mukesh Gupta
  • 1,373
  • 3
  • 17
  • 42
  • 1
    You need to add the jar to your classpath. See https://stackoverflow.com/questions/10386869/how-do-i-add-jar-files-to-the-classpath for running via command line. See https://stackoverflow.com/questions/3280353/how-to-import-a-jar-in-eclipse for adding jar to eclipse build path. – Sripriya V May 31 '17 at 04:01
  • thanks it solves my problem – Mukesh Gupta May 31 '17 at 04:17

0 Answers0