Results 1 to 4 of 4

Thread: using the debugger (javag)

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Dec 2001
    Posts
    1,331

    using the debugger (javag)

    Hello

    I was using the debugger and stepping through the code, and l want to see what values are currenlty in the variables. I consulted the documentation, and it said l need to compile the program using javag and then run in debug mode, as javag sets up all the information for the variables.

    But the problem is when compile in javag e.g. javag MyProgram.java it does not recongize javag.

    So l looked in the bin folder, and could not see it there, or anything that looks like it.

    Can you help

    Many thanks in advance

    Steve
    steve

  2. #2
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    You compile it using javac. There's a compiler switch to add/remove debug info, but I think it's on by default.

    The thing is that you need to debug the app while running, and that's quite tricky on the console. You need to start the app with special flags and then start the debugger javad in a second console.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  3. #3

    Thread Starter
    Frenzied Member
    Join Date
    Dec 2001
    Posts
    1,331
    Thanks for you help.

    It seems very complicated from what you said. About the setting of flags. When l read the documentation is said that you only have to compile in javag to get the bug information.

    My problem is that l don't have the javag to compile with. example

    javag MyProgram.java
    and then
    javadb MyProgram

    That should should, going by the documentation create the bug information.

    Any help with the javag will be very grateful

    Thanks in advance

    Steve
    steve

  4. #4
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    I never heard of javag, there is certainly no such program in the Sun Java SDK.
    However, you can easy debugging if you use an IDE like the free NetBeans (www.netbeans.org).
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width