• Post Reply Bookmark Topic Watch Topic
  • New Topic

Refresh table after inserting

 
Timuçin Çiçek
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a jTable which brings records from database.I can add contacts with add button to database.When i complete inserting i wanna see added contacts on jTable.How can i do this?Here's my addButton.It adds contacts database correctly.But cant refresh jtable.

 
Maneesh Godbole
Bartender
Posts: 11445
18
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch
You have all the code ready, except the model. Is that where you are facing a problem?
 
Paul Clapham
Sheriff
Posts: 21889
36
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You even have code which gets the model from the view. But I don't see any code which modifies that model, so that's why you don't see any change in its view. You need code which adds a row to the model based on what you inserted into the database.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!