Hello,
I am currently struck! I need a way to stop an already ongoing process by a button, using another button.
Explanation:-
1st Button Action

private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {                                         
.
.
some actions which is a ongoing running (for ex: timer countdown)
.
.
    }       

2nd Button Action

private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {    
    .
    .
    Stop the action of button 1 (like stop the timer created by button 1)
    .
    .

           }
    }         

Don't bother to answer.
Solved anyways....
This forum is good for nothing
Only TROLLS

only trolls? is that why you are on it?
has it occured to you that maybe nobody replied because you're description was way to vague?

my guess, starting a thread which is defined in the main class, and pausing or stopping it when clicking it on the second button.

do understand, we are not online 24/7. we do have lives, even jobs, the most of us, or studies. just because you don't get an immediate answer, or sometimes no answer at all, doesn't mean nobody wants to help you.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.