| Author |
Message |
|
|
Post subject: Cant see actual variables while debugging java files
Posted: Sep 23, 2008 - 10:57 PM
|
|
Joined: Sep 23, 2008
Posts: 3
|
|
When my breakpoint is hit during run time, I cant see the actual variables from my java files under variables list, I only see this, arg1, arg2 etc. I'm using tomcat as webserver and I checked the jdk that it runs and the the jdk used by eclipse to build the files..those are the same version jdk 1.5_11
I can see the variables when i hit a breakpoint in my JSPfiles , but not in java. How do i resolve this issue? Thanks in advance for the help.
-LR |
|
|
| |
|
|
|
 |
|
|
Post subject: RE: Cant see actual variables while debugging java files
Posted: Sep 24, 2008 - 05:37 PM
|
|
Registered Member


Joined: Apr 18, 2007
Posts: 5657
|
|
LR,
I would like you to try something out:-
1. Create a new Java Project.
2. Add a new class file to this project called TestClass with a main method.
3. Paste the following code in your class:-
| Code: |
public class TestClass {
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
int i=0;
i=i+i;
i=i++;
i++;
System.out.println(i);
}
}
|
4. Add a break point to the line where the variable i has been declared (int i=0;)
5. Right click on your TestClass and go to Debug As > Java Application.
6. Switch to the debug perspective and check if i shows up under the Variable Window.
Incase i doesn't show up, please go to MyEclipse > Installation Summary > Installation Details and paste the information here for me. |
_________________ Nipun
MyEclipse Support
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Sep 24, 2008 - 05:54 PM
|
|
Joined: Sep 23, 2008
Posts: 3
|
|
Nipun,
I tried that and when it hit the breakpoint, I can see the variable i in the list, but the same is not happening for my other projects, any idea why this is happening?
Here is the installation details:
*** Date:
Wednesday, September 24, 2008 12:54:34 PM EDT
** System properties:
OS=Windows2003
OS version=5.2
Java version=1.5.0_11
*** MyEclipse details:
MyEclipse Enterprise Workbench
Version: 5.5.1 GA
Build id: 20070521-5.5.1-GA
*** Eclipse details:
MyEclipse Enterprise Workbench
Version: 5.5.1 GA
Build id: 20070521-5.5.1-GA
Eclipse Graphical Editing Framework
Version: 3.2.2.v20070208
Build id: 20070208-1315
Eclipse Platform
Version: 3.2.2.r322_v20070119-RQghndJN8IM0MsK
Build id: M20070212-1330
Eclipse RCP
Version: 3.2.2.r322_v20070104-8pcviKVqd8J7C1U
Build id: M20070212-1330
Eclipse Java Development Tools
Version: 3.2.2.r322_v20070104-R4CR0Znkvtfjv9-
Build id: M20070212-1330
Eclipse Plug-in Development Environment
Version: 3.2.1.r321_v20060823-6vYLLdQ3Nk8DrFG
Build id: M20070212-1330
Eclipse Project SDK
Version: 3.2.2.r322_v20070104-dCGKm0Ln38lm-8s
Build id: M20070212-1330
Eclipse startup command=-os
win32
-ws
win32
-arch
x86
-launcher
C:\Program Files (x86)\MyEclipse 5.5.1 GA\eclipse\eclipse.exe
-name
Eclipse
-showsplash
600
-exitdata
1380_f4
-vm
C:\Program Files (x86)\MyEclipse 5.5.1 GA\jre\bin\javaw.exe
-LR |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Sep 25, 2008 - 08:33 PM
|
|
Registered Member


Joined: Apr 18, 2007
Posts: 5657
|
|
I hope the project has not gone corrupt. You can try using the -clean command to try and fix this issue but incase that doesn't help, you might have to create a new project and transfer your code to the new project to continue working.
http://www.myeclipseide.com/PNphpBB2-viewtopic-t-10280.html |
_________________ Nipun
MyEclipse Support
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Sep 26, 2008 - 06:13 AM
|
|
Joined: Sep 23, 2008
Posts: 3
|
|
Nipun,
I used the -clean command and that fixed the issue. Thanks for your time.
-LR |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Sep 26, 2008 - 08:09 PM
|
|
Registered Member


Joined: Apr 18, 2007
Posts: 5657
|
|
| Glad you got it to work. Thanks for letting me know. |
_________________ Nipun
MyEclipse Support
|
| |
|
|
|
 |
|
|