Search:

Type: Posts; User: squeakbox

Search: Search took 0.08 seconds.

  1. [SOLVED] Re: Code from textbook not working and I don't know why--Event-driven programming

    I learned to read errors with someone pointing them out to me, and I find I can read errors myself fine now.
    I'm sure they'll figure it out down the line.
  2. [SOLVED] Re: Code from textbook not working and I don't know why--Event-driven programming

    You seem to have written "JTextField paymentField = new JTextField(10);" when you already have "private JTextField paymentField;" at the top as well.
  3. [SOLVED] Re: Code from textbook not working and I don't know why--Event-driven programming

    Alright.

    Well I copyed & pasted your code, and I found the problem. You didn't create "paymentField = new JTextField();", in my IDE, your paymentField comes up as inactive.
  4. [SOLVED] Re: Code from textbook not working and I don't know why--Event-driven programming

    Try this:
    Instead of putting variables such as "double payment" inside your methods, put them with your instance variables, like:

    "private double payment;"

    set them to 0 in your constructor:
    ...
  5. [SOLVED] Re: Code from textbook not working and I don't know why--Event-driven programming

    [removed - sorry, accidental double-post]
Results 1 to 5 of 5