File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to restart a button, bring it to the intial state (actionlistener, threads)

 
zhe zen
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am adapting an applet from some open source code to my need and have a problem with reseting the its applet to the initial state.
The Applet has two buttons: "Run" and "Reset".
runbutton starts an algorithm, which is in a runnable class.
resetbutton is currently just reseting the parameters of this algorithm to the intial state.

I would like to reset the applet with a button, so that when i press the runbutton the applet is just at the same stage as befor pressing the start button for the first time.

Here the crucial parts of the code:



The network class:



Thanks a lot for all help.

Zhe
 
Rob Spoor
Sheriff
Pie
Posts: 20372
44
Chrome Eclipse IDE Java Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please Use Code Tags. You can edit your post to add them.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic