guys, good day!

I just want to ask how to reload/refresh a JComboBox. I have a cardlayout with 3 panels, each panel has its own combobox. what I want to do is to reload the combobox to its original state each time I swap the cardlayout.

updateUI();
repaint();
revalidate();

I did try to use these classes but failed.

Recommended Answers

use ComboBoxModel

Jump to Post

All 4 Replies

use ComboBoxModel

use ComboBoxModel

can you show a simple example? thanks

Problem Solve... Thanks

Be a part of the DaniWeb community

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