Search:

Type: Posts; User: pbrockway2

Search: Search took 0.18 seconds.

  1. Replies
    8
    Views
    1,381

    Re: Event Handler For a JTextField

    I'm glad you've got it sorted out.

    There seem to be some other problems with that event handler that should come to light as you test it. (Make sure the answers you get are reasonable!)
  2. Replies
    8
    Views
    1,381

    Re: Event Handler For a JTextField

    You read the stack trace from the top down until you reach a line which mentions your code. This is a good place to begin looking for the source of the problem.

    In this case the problem is...
  3. Replies
    8
    Views
    1,381

    Re: Event Handler For a JTextField

    You have variables like distance declared twice and this is causing no end of problems.

    At the risk of repeating myself, having sensible (descriptive) variables stops the problem from ever...
  4. Replies
    8
    Views
    1,381

    Re: Event Handler For a JTextField

    That doesn't look right to me because MPG is a JLabel with the text "What is the Vehicles MPG?". And parsing that text as a float won't lead to anything good...

    ---

    A couple of observations -...
Results 1 to 4 of 4