File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes addItemListener error message Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "addItemListener error message" Watch "addItemListener error message" New topic
Author

addItemListener error message

Dan Nissen
Greenhorn

Joined: Jun 06, 2002
Posts: 14
Hi All - I keep getting this error when I try to use addItemListener on a Choice or JComboBox. Can anyone please suggest to me why I recieve this error?
C:\Program Files\Xinox Software\JCreator Pro\MyProjects\DealerNet\DealerNet.java:1149: addItemListener(java.awt.event.ItemListener) in java.awt.Choice cannot be applied to (DealerNet)
DAppCreditEmpStatus.addItemListener(this);
The Full code can be found at Code.
Thanks
Dan
David G Risner
Ranch Hand

Joined: May 02, 2002
Posts: 30
It is because your class is not an ItemListener. Either your class needs to implement the ItemListener interface or you need to create an inner class that implements ItemListener and have it take care of whatever tasks are needed.


David G. Risner<br />Software Engineer<br />California State University, Los Angeles
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: addItemListener error message
 
Similar Threads
for Applet
What kind of error is this?
To many Frames
Frame Attack!
CheckboxGroup in Dialog