sorry, i didnt quite get what you are saying should i add any jar files, should i add any external jar files. Please elaborate
Main Topics
Browse All TopicsHi,
I am sure this error should have come to many but i didnt see the answer for Myeclipse in Mac environment.
I tried with a simple java program which prints welcome, and it is working fine in the run mode but
When i try to debug a simple java code by setting the breakpoint it give me the following error
Source not found
edit source lookup path
I am trying to add the source path by trying to add the folder where the source exists but i still get the same error.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
I am saying that the error is common if during debug stage you click on the 'step into' button on a method for which you don't have source code (or at least the code is not in the project being debugged). If you have the source code in a related project in your workspace, then you can click on the button as instructed to do the lookup. If this is a class you only have the compiled JAR for, you can just click on 'step to return' to get paste that.
Regards,
--isa
Try picking down at the source folder level OR at your top level package. Just to see if it is an issue with the nested folder structure as you have project folder then another folder under it with same name as project then your bin / src folder. IIRC, the source folder level is what you want as it will then walk the other folders based on your package structure. If you set the path too high, then it won't find your classes as it will be looking for them in the root or for package structure from the root which doesn't exist.
Maybe it is a Mac thing I am just not use to as I have used Mac's but have not used Eclipse on one before.
Just in case, let's verify, when you are creating your project (e.g., MyProject) ensure to set your source folder(s) to be something like :src or :code?
Once the project is created, try creating a package called "kalyangkm", which should give you the structure MyProject:src:kalyangkm.
Now, with kalyangkm highlighted / selected in Eclipse, create new class (e.g., WelcomeKalyan -- note that is more to standard naming conventions that Welcome_Kalyan).
Repeat this process to create a class in another project (e.g., OtherProject) and then call your class kalyangkm.WelcomeKalyan. You should get errors that require you to update build path of OtherProject to include MyProject as a related project / reference -- do so to resolve issues and compile.
Debug the second class (in OtherProject) and see if [1] you get the same issue with debugger needing the source path and [2] when you click lookup and select the path (again I believe this to be the folder src or code from example) does it work or not.
Also, regarding version, there is a MyEclipse 7 -- so see if anything here helps:
http://www.myeclipseide.co
It is a discussion on the same topic for MyEclipse.
--isa
i was trouble calling class of another project in some other project though i initialized public for both of them. I am struggling to include the current sytax for importing the package of one project into another. i dont know if its again mac thing.
Currently using bootcamp i got windows installed into the sytem and and instlled myeclipse 7.5 and now i am able to debug, Mac sucks for me for the first time. Looking forward for your advice for future issues, Thanks.
My last post has some instructions that should help. Once you have made a project a dependency for the other, then in the second project you would can do the imports like this as long as the class in the first project is set to public access.
In other words, this is class from project 1.
package kalyangkm;
public class WelcomeKalyan {
public static void main(String[] args) {
System.out.println("Welcom
}
}
In second project, with build path set correctly.
package testpackage;
import kalyangkm.WelcomeKalyan;
class TestWelcomeKalyan {
public static void main(String[] args) {
WelcomeKalyan.main(args);
}
}
Alternatively, you can fully qualify the class to avoid the import (e.g., kalyangkm.WelcomeKalyan.ma
Hope that helps.
--isa
attached are the screen shots of package explorer showing 2 different projects and the 2 .java files.
Initially i tried to use kalyangkm and gkmadhav packages in 2 different projects and trying to call the class of one in another, it didnt work when i tried to import using your syntax in the gkmadhav package.
Then i imported the entire kalyangkm package into the second project thats when the syntax worked but the issue with the debugging persists.
Thanks
kalyan.
Sorry for the delay.
That worked perfectly fine for me.
However, I think I may understand what you are doing why you are getting the error. It goes back to my earlier explanation on lookup source on API objects for which you do NOT have source code, but from what I found it is probably not code you are using in your application.
What worked for me was to put a breakpoint on this line of code:
WelcomeKalyan.main(args);
Then Debug the WelcomeMadhav using Debug As | Java Application. The screen in image 'step 1' below comes up, at which point I click 'step into'. Then the screen in image 'step 2' comes up allowing me to debug the code in WelcomeKalyan class (as you can see it is working). From here, I can 'step to return' which will put me back into WelcomeMadhav. When at the bottom of WelcomeMadhav or done debugging, I hit 'resume' as shown in image 'success'.
Now regarding the last sentence above, if I don't hit resume when exiting my class but instead hit 'step over' or 'step into', the debugger thinks I want to debug the Thread.exit() method. This is where I get the source not found message as shown in image 'error'.
This is not a problem and you don't need to debug that, so you should be fine. If for some reason this is still not functioning correctly, I would try a clean installation of MyEclipse and then re-import your projects or switch to normal Eclipse where I did my testing.
Regards,
--isa
Double check that you followed this process.
+Right-click project containing class WelcomeMadhav, select Build Path | Configure Build Path
+In the Java Build Path dialog window, select Projects tab
+Click on the Add button
+On the Required Project Selection, check the box next to the project containing WelcomeKalyan class and click OK
+Click OK to apply settings in Java Build Path window
That should work.
Business Accounts
Answer for Membership
by: mwvisa1Posted on 2009-08-24 at 02:25:24ID: 25166655
kalyangkm,
(suspect you mean Eclipse 3.5, but doesn't matter)
The error you are referring too is when you try to step into a method (code) that is for a class whose source file is not immediately available. Either it is in another project within your workspace at which point you can use the lookup as indicated or it is a standard API that you only have JAR with class files for and not the actual source.
This is very common.
--isa