Win a copy of Rust Web Development this week in the Other Languages forum!

Lily Tan

Greenhorn
+ Follow
since May 01, 2012
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Lily Tan

After values have been added into the database, the JTable does not display the new data unless I terminate and execute the program again.
Am I supposed to use fireTableDataChanged or newDataAvailable?

I'm using DefaultTableModel:


And the table should refresh after I click the button:



Thanks in advance!
9 years ago

Darryl Burke wrote:Hello Lily and welcome to the Ranch!

Do you have a problem, and a more specific question, that we can help you with? If it's not directly about adding items to a JComboBox at runtime, then start a new thread.



Hi Darryl,

I'm encountering similar problems that's why I'm asking Luke since he solved it
New data are added into the database from a text field.
My combo box does not display the new data unless i terminate and execute the application again.
9 years ago

luke lukes wrote:it worked :-)


what changes did you make for it to work?
9 years ago