Search:

Type: Posts; User: GregBrannon

Search: Search took 0.09 seconds.

  1. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    What you describe cannot be done without changing the JOptionPane to a JDialog, a technique you would have found by searching the web as I suggested in Post #2. There's actually a JOptionPane method...
  2. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    With the commented lines uncommented, you should be getting this compiler error:

    File: C:\Java Source\TimerTest.java [line: 22]
    Error: Cannot refer to a non-final variable sc inside an inner...
  3. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    Compiler errors. Do you have any of those?
  4. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    No compiler errors? Believe me, there's an error, and it's the primary reason your code is not working as you'd like.

    If you're not seeing the error, that's a bigger problem, and that's why I...
  5. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    Focusing on the new feature you're trying to learn with a simple study program is an excellent approach.

    What do you mean "IT WON'T WORK?" If you're getting errors, post them.
  6. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    Why are you still using variables like d1, d2, . . ., dx instead of an array? Having a collection of variables that can be iterated with a loop greatly simplifies the if logic. The long chains of...
  7. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    That's fine. Search around a bit for examples or advice about using a javax.swing.Timer, attempt to code it, and come back if/when you need help. Since your code is likely mostly contained in a...
  8. Replies
    21
    Views
    1,564

    [SOLVED] Re: About swing Timer in my Math game

    What did you find when you searched "joptionpane with timer" or similar?

    Do you have to use JOptionPane, or are you ready to advance to a JFrame with JDialogs?

    Your English is better than good...
Results 1 to 8 of 8