| Author |
java.lang.IllegalThreadStateException
|
Urs Waefler
Ranch Hand
Joined: Mar 13, 2007
Posts: 77
|
|
Hi
This is my code:
I do not understand java.lang.IllegalThreadStateException? How should I correct my code?
Regards, Urs
|
SCJP 1.4
|
 |
William Brogden
Author and all-around good cowpoke
Rancher
Joined: Mar 22, 2000
Posts: 12271
|
|
Where is the rest of the Exception stack trace? That information is generated to help you understand the cause, don't throw it away.
Bill
|
Java Resources at www.wbrogden.com
|
 |
Urs Waefler
Ranch Hand
Joined: Mar 13, 2007
Posts: 77
|
|
It looks like that:
Exception in thread "main" java.lang.IllegalThreadStateException
at java.lang.Thread.start(Unknown Source)
at Banking.main(Banking.java:93)
How can I correct this issue?
|
 |
Raaghu Kannan
Greenhorn
Joined: Aug 19, 2011
Posts: 8
|
|
You are starting the same thread twice
Once in Clerk Constructor
Once in your main method.
Remove one of them , better to remove from Constructor.
Thanks and Regards
Raaghu.K
|
 |
 |
|
|
subject: java.lang.IllegalThreadStateException
|
|
|