How to use ActionListener and ItemListener together in one java program??

Since they are interfaces, you can implement more than 1:

public class MyFrame extends JFrame implements ActionListener, ItemListener {

}

Don't forget to add the methods that these interfaces have. Also to add the "listeners" to the components you are interested (buttons)

commented: Credit is given where credit is due +3

:) Thanks a lot for helping me !!!!!!!!!!!!!!!!!!!!

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.